com.gargoylesoftware.htmlunit
Class UnexpectedPage

java.lang.Object
  extended by com.gargoylesoftware.htmlunit.UnexpectedPage
All Implemented Interfaces:
Page

public class UnexpectedPage
extends java.lang.Object
implements Page

A generic page that is returned whenever an unexpected content type is returned by the server.

Version:
$Revision: 1.3 $
Author:
Mike Bowler, David K. Taylor

Constructor Summary
UnexpectedPage(WebResponse webResponse, WebWindow enclosingWindow)
 Create an instance
 
Method Summary
 void cleanUp()
 Clean up this page.
 WebWindow getEnclosingWindow()
 Return the window that this page is sitting inside.
 java.io.InputStream getInputStream()
 Return an input stream representing all the content that was returned from the server.
 WebResponse getWebResponse()
 Return the web response that was originally used to create this page.
 void initialize()
 Initialize this page.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UnexpectedPage

public UnexpectedPage(WebResponse webResponse,
                      WebWindow enclosingWindow)
Create an instance

Parameters:
webResponse - The response from the server that contains the data required to create this page
enclosingWindow - The window that this page is being loaded into.
Method Detail

cleanUp

public void cleanUp()
Clean up this page.

Specified by:
cleanUp in interface Page

getEnclosingWindow

public WebWindow getEnclosingWindow()
Return the window that this page is sitting inside.

Specified by:
getEnclosingWindow in interface Page
Returns:
The enclosing frame or null if this page isn't inside a frame.

getInputStream

public java.io.InputStream getInputStream()
                                   throws java.io.IOException
Return an input stream representing all the content that was returned from the server.

Returns:
See above.
Throws:
java.io.IOException - If an IO error occurs

getWebResponse

public WebResponse getWebResponse()
Return the web response that was originally used to create this page.

Specified by:
getWebResponse in interface Page
Returns:
The web response

initialize

public void initialize()
Initialize this page.

Specified by:
initialize in interface Page


Copyright © 2003-2009 AppPerfect Corporation. All Rights Reserved.