/** * get the received Page * @return the received page * @throws SAXException */ HTMLPage getReceivedPage() throws SAXException { if (_page == null) { try { _parsingPage = true; if (!isHTML()) throw new NotHTMLException( getContentType() ); _page = new HTMLPage( this, _frame, _baseURL, _baseTarget, getCharacterSet() ); _page.parse( getText(), _pageURL ); if (_page == null) throw new IllegalStateException( "replaceText called in the middle of getReceivedPage()" ); ((HTMLDocumentImpl) _page.getRootNode()).getWindow().setProxy( this ); } catch (IOException e) { HttpUnitUtils.handleException(e); throw new RuntimeException( e.toString() ); } finally { _parsingPage = false; } } return _page; }
/** * get the received Page * @return the received page * @throws SAXException */ HTMLPage getReceivedPage() throws SAXException { if (_page == null) { try { _parsingPage = true; if (!isHTML()) throw new NotHTMLException( getContentType() ); _page = new HTMLPage( this, _frame, _baseURL, _baseTarget, getCharacterSet() ); _page.parse( getText(), _pageURL ); if (_page == null) throw new IllegalStateException( "replaceText called in the middle of getReceivedPage()" ); ((HTMLDocumentImpl) _page.getRootNode()).getWindow().setProxy( this ); } catch (IOException e) { HttpUnitUtils.handleException(e); throw new RuntimeException( e.toString() ); } finally { _parsingPage = false; } } return _page; }
/** * get the received Page * @return the received page * @throws SAXException */ HTMLPage getReceivedPage() throws SAXException { if (_page == null) { try { _parsingPage = true; if (!isHTML()) throw new NotHTMLException( getContentType() ); _page = new HTMLPage( this, _frame, _baseURL, _baseTarget, getCharacterSet() ); _page.parse( getText(), _pageURL ); if (_page == null) throw new IllegalStateException( "replaceText called in the middle of getReceivedPage()" ); ((HTMLDocumentImpl) _page.getRootNode()).getWindow().setProxy( this ); } catch (IOException e) { HttpUnitUtils.handleException(e); throw new RuntimeException( e.toString() ); } finally { _parsingPage = false; } } return _page; }