Android webview Access the DOM
<p>I've come up with an simple question. I would like to get the DOMDocument of the Android webview.</p>

<p>What I've done to solve this:</p>

<ul>
<li>Google this</li>
<li>Reading the docs</li>
<li>wrote this question</li>
</ul>

<p>What I've found is this:</p>

<ul>
<li>Over hundred of people who say you can't access this.</li>
<li>While working the webview layout didn't get any children in the debug view of an IDE.</li>
</ul>

<p>And here more questions of mine:</p>

<ul>
<li>Isn't there any way to get this object?</li>
<li>Which object has an reference to this object or owns the DOMDocument?</li>
<li>Does the webview just reinterprete the document into a layout or does the webview realy draws the document?</li>
</ul>

<p>Thanks to everyone who can give a hint or answer these questions.</p>

<p>EDIT:
As mentioned I could use a js interface but I do not use this to keep the js environment clean and do not create any variable which could create an issuse with the javascript on webpage.</p>

<pre><code>WebView.evaluateJavascript(
"function(){return "JSON";})();",
new ValueCallback&lt;String&gt;(){ 
    public void onRecieveValue(String p1){
    //TODO : CODE HERE
    }
});
</code></pre>