com.gargoylesoftware.htmlunit
Interface WebWindow

All Known Implementing Classes:
FrameWindow, TopLevelWindow, WebWindowImpl

public interface WebWindow

An interface that represents one window in a browser. It could be a top level window or a frame.

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

Method Summary
 Page getEnclosedPage()
 Return the currently loaded page or null if no page has been loaded.
 java.lang.String getName()
 Return the name of this window.
 WebWindow getParentWindow()
 Return the window that contains this window.
 java.lang.Object getScriptObject()
 INTERNAL API - SUBJECT TO CHANGE AT ANY TIME - USE AT YOUR OWN RISK.
 ThreadManager getThreadManager()
 INTERNAL API - SUBJECT TO CHANGE AT ANY TIME - USE AT YOUR OWN RISK.
 WebWindow getTopWindow()
 Return the top level window that contains this window.
 WebClient getWebClient()
 Return the web client that "owns" this window.
 void setEnclosedPage(Page page)
 Set the currently loaded page.
 void setName(java.lang.String name)
 Set the name of this window.
 void setScriptObject(java.lang.Object scriptObject)
 INTERNAL API - SUBJECT TO CHANGE AT ANY TIME - USE AT YOUR OWN RISK.
 

Method Detail

getEnclosedPage

Page getEnclosedPage()
Return the currently loaded page or null if no page has been loaded.

Returns:
The currently loaded page or null if no page has been loaded.

getName

java.lang.String getName()
Return the name of this window.

Returns:
The name of this window.

getParentWindow

WebWindow getParentWindow()
Return the window that contains this window. If this is a top level window, then return this window.

Returns:
The parent window or this window if there is no parent.

getScriptObject

java.lang.Object getScriptObject()
INTERNAL API - SUBJECT TO CHANGE AT ANY TIME - USE AT YOUR OWN RISK.
Return the javascript object that corresponds to this element.

Returns:
The javascript object that corresponds to this element.

getThreadManager

ThreadManager getThreadManager()
INTERNAL API - SUBJECT TO CHANGE AT ANY TIME - USE AT YOUR OWN RISK.
Currently exposed here for testing purposes, a better API will be added in the future and this will become a completely internal class.

Returns:
The ThreadManager for this WebWindow

getTopWindow

WebWindow getTopWindow()
Return the top level window that contains this window. If this is a top level window, then return this window.

Returns:
The top level window that contains this window or this window if there is no parent.

getWebClient

WebClient getWebClient()
Return the web client that "owns" this window.

Returns:
The web client or null if this window has been closed.

setEnclosedPage

void setEnclosedPage(Page page)
Set the currently loaded page.

Parameters:
page - The new page or null if there is no page (ie empty window)

setName

void setName(java.lang.String name)
Set the name of this window.

Parameters:
name - The new window name.

setScriptObject

void setScriptObject(java.lang.Object scriptObject)
INTERNAL API - SUBJECT TO CHANGE AT ANY TIME - USE AT YOUR OWN RISK.
Set the javascript object that corresponds to this element. This is not guaranteed to be set even if there is a javascript object for this html element.

Parameters:
scriptObject - The javascript object.


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