From: Rural H. <rur...@gm...> - 2016-09-02 08:38:01
|
This is the source code in the end of the function: // start execution here // note: we have to do this also if the server reports an error! // e.g. if the server returns a 404 error page that includes javascript if (scriptEngine_ != null) { scriptEngine_.registerWindowAndMaybeStartEventLoop(webWindow); } // check and report problems if needed throwFailingHttpStatusCodeExceptionIfNecessary(webResponse); return (P) webWindow.getEnclosedPage(); For a simple use of a webClient.getPage("http://some.url"), my concern is, if the page loaded has some delay script(such as by using setTimeout() javascript function with setting self.location to another url) to replace the page in the top window, the page return immediately here will not be the expected final page, am I correct? |