title: how to get webview content android after loadurl
body: <p>Here is My Code.</p>
  
  <p>I just want to get the page content from the Webview after load the URL .</p>
  
  <p>On Android, I have a WebView that is displaying a page.</p>
  
  <p>How do I get the page source without requesting the page again?</p>
  
  <p>It seems WebView should have some kind of WebResourceResponse () method in Android 3.0 but don't know how to use it.</p>
  
  <pre><code> public class WebActivity extends Activity {
  WebView mWebView;
  
  /** Called when the activity is first created. */
  @Override
  public void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.main);
  
      mWebView = (WebView) findViewById(R.id.webView);
      mWebView.getSettings().setJavaScriptEnabled(true);
      mWebView.loadUrl("https://xyz.com");
      mWebView.setWebViewClient(new HelloWebViewClient());
  
  
  
   }
  
  
  
         private class HelloWebViewClient extends WebViewClient  {
  
        public WebResourceResponse shouldInterceptRequest (WebView view, String url)
        {
          return null;
  
  
        }
  
        @Override
          public void onPageFinished(WebView view, String url)
          {
             /* This call inject JavaScript into the page which just finished loading. */
             mWebView.loadUrl("javascript:window.HTMLOUT.processHTML('&lt;head&gt;'+document.getElementsByTagName('html')[0].innerHTML+'&lt;/head&gt;');");
  
          }
      @Override
      public boolean shouldOverrideUrlLoading(WebView view, String url) {
          view.loadUrl(url);
          return true;
      }
  }
      public boolean shouldOverrideUrlLoading(WebView view, String url) {
      view.loadUrl(url);
      return true;
  }
  
  
  @Override
  public boolean onKeyDown(int keyCode, KeyEvent event) {
      if ((keyCode == KeyEvent.KEYCODE_BACK) &amp;&amp; mWebView.canGoBack()) {
          mWebView.goBack();
          return true;
      }
      return super.onKeyDown(keyCode, event);
  }}
  </code></pre>