IBM Rational Functional Tester
Version 8.1.1000
IBM Rational Functional Tester Proxy SDK Reference

Project Version 2.3

com.rational.test.ft.domain.java
Class Java2TestDomainImplementation

java.lang.Object   extended by com.rational.test.ft.domain.TestDomain
      extended by com.rational.test.ft.domain.TestDomainImplementation
          extended by com.rational.test.ft.domain.java.TestDomainImplementationJava
              extended by com.rational.test.ft.domain.java.Java2TestDomainImplementation
All Implemented Interfaces:
java.awt.event.AWTEventListener, java.util.EventListener

public class Java2TestDomainImplementation
extends TestDomainImplementationJava
implements java.awt.event.AWTEventListener

The "assistive_technology" class that gets loaded as an accessibility interface. This class tracks and allows access to top-level windows in much the same way that the Sun EventQueueMonitor class allows this access. Using the EventQueueMonitor class provides greater functionality than needed. Therefore, a stripped-down version is used here instead.


Field Summary
protected static com.rational.test.ft.util.FtDebug debug
           
static java.lang.String SHELL_EMBEDDING
           
 
Fields inherited from class com.rational.test.ft.domain.java.TestDomainImplementationJava
IGNORE_MOUSE_DOUBLECLICK_THRESHOLD, IGNORE_MOUSE_DRAG
 
Constructor Summary
Java2TestDomainImplementation()
           
 
Method Summary
 void eventDispatched(java.awt.AWTEvent theEvent)
          Called when events are generated by the AWTEventListener logic.
 com.rational.test.ft.object.manager.FindResult find(com.rational.test.ft.object.map.IMappedTestObject[] pathToFind)
           
 ProxyTestObject getCrossDomainProxy(com.rational.test.ft.sys.graphical.Window hwnd)
           
 ProxyTestObject getDescribedObject(DescribedObject describedObject)
          Find the object described by the set of properties in the DescribedObject.
 ProxyTestObject[] getProxiesForWindow(com.rational.test.ft.sys.graphical.Window hwnd)
           
 ProxyTestObject getTopLevelObject(com.rational.test.ft.sys.graphical.Window window)
          Returns the topLevelObject that matches the specified window; throws an exception if the domain is not isGraphical.
 ProxyTestObject getTopLevelObject(com.rational.test.ft.sys.graphical.Window topWindow, com.rational.test.ft.sys.graphical.Window pointWindow)
          Returns the topLevelObject that matches the specified window; throws an exception if the domain is not isGraphical.
 java.util.Enumeration getTopLevelObjects()
          Return an enumeration for the top-level objects within this domain implementation.
 java.util.Enumeration getTopLevelObjects(IChannel channel)
           
protected  java.awt.Window[] getTopLevelWindows()
          Returns an array of top-level windows from the top-level windows list that is maintained statically.
 java.awt.Window getTopLevelWindowWithFocus()
          Returns the last top-level window to be activated, which contains the component with focus.
 void initialize()
          Register this class as an event listener.
 
Methods inherited from class com.rational.test.ft.domain.java.TestDomainImplementationJava
getActionRecordingFlags, getDomainProxy, getImplementationName, getProxy, getTheDomainImplementation, IAmTheOne, registerFromSwtUIThread, registerProxies
 
Methods inherited from class com.rational.test.ft.domain.TestDomainImplementation
equals, supportVOMOptimization
 
Methods inherited from class com.rational.test.ft.domain.TestDomain
getName, isGraphical, isNamed
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

debug

protected static com.rational.test.ft.util.FtDebug debug

SHELL_EMBEDDING

public static java.lang.String SHELL_EMBEDDING
Constructor Detail

Java2TestDomainImplementation

public Java2TestDomainImplementation()
Method Detail

getTopLevelObjects

public java.util.Enumeration getTopLevelObjects()
Return an enumeration for the top-level objects within this domain implementation.

Specified by:
getTopLevelObjects in class TestDomainImplementation

getTopLevelObjects

public java.util.Enumeration getTopLevelObjects(IChannel channel)

getTopLevelObject

public ProxyTestObject getTopLevelObject(com.rational.test.ft.sys.graphical.Window window)
Returns the topLevelObject that matches the specified window; throws an exception if the domain is not isGraphical. If the Window cannot be matched, a null value is returned. Channel will be switched for SWT.

Specified by:
getTopLevelObject in class TestDomainImplementation
Parameters:
window - The window object to match.
Returns:
The top-level object matching window in this test domain or null if not found.

getTopLevelObject

public ProxyTestObject getTopLevelObject(com.rational.test.ft.sys.graphical.Window topWindow,                                          com.rational.test.ft.sys.graphical.Window pointWindow)
Returns the topLevelObject that matches the specified window; throws an exception if the domain is not isGraphical. If the Window cannot be matched, a null value is returned. Channel will be switched for SWT.

Overrides:
getTopLevelObject in class TestDomainImplementation
Parameters:
window - The window object to match.
Returns:
The top-level object matching window in this test domain or null if not found.

initialize

public void initialize()
Register this class as an event listener. An AWTEventListener gets to listen to all desired events. Keep track of the window-specific events and, in particular, the creation and destruction events.


eventDispatched

public void eventDispatched(java.awt.AWTEvent theEvent)
Called when events are generated by the AWTEventListener logic.

Specified by:
eventDispatched in interface java.awt.event.AWTEventListener
Parameters:
theEvent - Any requested events as they are generated.

getTopLevelWindows

protected java.awt.Window[] getTopLevelWindows()
Returns an array of top-level windows from the top-level windows list that is maintained statically.

Returns:
The top-level windows in an array format.

getTopLevelWindowWithFocus

public java.awt.Window getTopLevelWindowWithFocus()
Returns the last top-level window to be activated, which contains the component with focus.

Returns:
The top-level window with focus or null if no Java window from this process is known to have focus.

getDescribedObject

public ProxyTestObject getDescribedObject(DescribedObject describedObject)
Description copied from class: TestDomainImplementation
Find the object described by the set of properties in the DescribedObject.

Overrides:
getDescribedObject in class TestDomainImplementation

getProxiesForWindow

public ProxyTestObject[] getProxiesForWindow(com.rational.test.ft.sys.graphical.Window hwnd)
Overrides:
getProxiesForWindow in class TestDomainImplementationJava

getCrossDomainProxy

public ProxyTestObject getCrossDomainProxy(com.rational.test.ft.sys.graphical.Window hwnd)

find

public com.rational.test.ft.object.manager.FindResult find(com.rational.test.ft.object.map.IMappedTestObject[] pathToFind)
Overrides:
find in class TestDomainImplementation