List of usage examples for android.webkit URLUtil stripAnchor
public static String stripAnchor(String url)
From source file:android.webkit.LoadListener.java
/** * Sets the current URL associated with this load. *//*w w w . j av a 2s .co m*/ void setUrl(String url) { if (url != null) { if (URLUtil.isDataUrl(url)) { // Don't strip anchor as that is a valid part of the URL mUrl = url; } else { mUrl = URLUtil.stripAnchor(url); } mUri = null; if (URLUtil.isNetworkUrl(mUrl)) { try { mUri = new WebAddress(mUrl); } catch (ParseException e) { e.printStackTrace(); } } } }