public class PaletteProxy extends JavaGuiProxy
LEFT, preDownState, processMouseEventHandler, ROLEINDEX, ROLEINDEXWEIGHT, TESTDATA_SPECIALFRAMESTATE, TESTDATA_SPECIALFRAMESTATE_DESCRIPTION, topLevelWindow
BROWSERTABTESTOBJECT_CLASSNAME, BROWSERTESTOBJECT_CLASSNAME, COLORDIALOGTESTOBJECT_CLASSNAME, CROSSDOMAINCONTAINER_CLASSNAME, DOCUMENTTESTOBJECT_CLASSNAME, DOMAINTESTOBJECT_CLASSNAME, ECLIPSETOPLEVELTESTOBJECT_CLASSNAME, EMBEDDEDBROWSERTESTOBJECT_CLASSNAME, FILEDIALOGTESTOBJECT_CLASSNAME, FRAMESUBITEMTESTOBJECT_CLASSNAME, FRAMETESTOBJECT_CLASSNAME, GEFEDITPARTTESTOBJECT_CLASSNAME, GUISUBITEMTESTOBJECT_CLASSNAME, GUITESTOBJECT_CLASSNAME, INTERNALFRAMETESTOBJECT_CLASSNAME, MESSAGEBOXTESTOBJECT_CLASSNAME, PALETTEGUISUBITEMTESTOBJECT_CLASSNAME, PROCESSTESTOBJECT_CLASSNAME, SCROLLSUBITEMTESTOBJECT_CLASSNAME, SCROLLTESTOBJECT_CLASSNAME, SELECTGUISUBITEMTESTOBJECT_CLASSNAME, SELECTSCROLLGUISUBITEMTESTOBJECT_CLASSNAME, SHELLTESTOBJECT_CLASSNAME, STATELESSGUISUBITEMTESTOBJECT_CLASSNAME, SUBITEMTESTOBJECT_CLASSNAME, TABITEMTESTOBJECT_CLASSNAME, TESTOBJECT_CLASSNAME, TEXTGUISUBITEMTESTOBJECT_CLASSNAME, TEXTGUITESTOBJECT_CLASSNAME, TEXTSCROLLTESTOBJECT_CLASSNAME, TEXTSELECTGUISUBITEMTESTOBJECT_CLASSNAME, TIMEOUTTESTOBJECT_CLASSNAME, TOGGLEGUITESTOBJECT_CLASSNAME, TOGGLETESTOBJECT_CLASSNAME, TOPLEVELSUBITEMTESTOBJECT_CLASSNAME, TOPLEVELTESTOBJECT_CLASSNAME, TRACKBARTESTOBJECT_CLASSNAME, vomClippedRectangle
INCLUDE_ALL, INCLUDE_JUSTOBJECT, INCLUDE_SIBLINGS
Constructor and Description |
---|
PaletteProxy(java.lang.Object theObjectInTheSUT)
Constructor for the proxy
|
Modifier and Type | Method and Description |
---|---|
void |
activateTopWindow()
Activate the palette Root before performing actions on them
|
void |
activateTopWindow(java.lang.Object paletteEntry)
Activate the palette Entry before performing actions on them
|
void |
click(MouseModifiers modifiers,
Subitem subitem)
Perform a mouse click action at the specified object relative
coordinates within the associated TestObject.
|
void |
click(MouseModifiers modifiers,
Subitem subitem,
java.awt.Point pt)
Perform a mouse click action on the specified coordinates relative
to the associated TestObject.
|
void |
click(Subitem subitem)
Left mouse click on the center point of the associated subitem.
|
void |
click(Subitem subitem,
java.awt.Point pt)
Left mouse click on the specified coordinates relative to the
associated TestObject.
|
void |
doubleClick(MouseModifiers modifiers,
Subitem subitem)
Perform a mouse dbl-click action at the specified object relative
coordinates within the associated TestObject.
|
void |
doubleClick(MouseModifiers modifiers,
Subitem subitem,
java.awt.Point pt)
Perform a mouse dbl-click action on the specified coordinates relative
to the associated TestObject.
|
void |
doubleClick(Subitem subitem)
Left mouse dbl-click on the center point of the associated TestObject.
|
void |
doubleClick(Subitem subitem,
java.awt.Point pt)
Left mouse dbl-click on the specified coordinates relative to the
associated TestObject.
|
void |
drag(MouseModifiers modifiers,
Subitem subitem)
Perform a drag action against the associated TestObject with the
supplied set of mouse modifiers.
|
void |
drag(MouseModifiers modifiers,
Subitem subitem1,
java.awt.Point pt1,
Subitem subitem2,
java.awt.Point pt2)
Perform a drag action against the associated TestObject.
|
void |
drag(MouseModifiers modifiers,
Subitem subitem1,
Subitem subitem2)
Perform a drag action against the associated TestObject.
|
void |
drag(Subitem subitem)
Perform a MOUSE_LEFT drag action against the associated TestObject.
|
void |
drag(Subitem subitem1,
java.awt.Point pt1,
Subitem subitem2,
java.awt.Point pt2)
Perform a MOUSE_LEFT drag action against the associated TestObject.
|
void |
drag(Subitem subitem1,
Subitem subitem2)
Perform a MOUSE_LEFT drag action against the associated TestObject.
|
void |
dragToScreenPoint(MouseModifiers modifiers,
Subitem subitem,
java.awt.Point screenPt)
Perform a drag action against the associated TestObject.
|
void |
dragToScreenPoint(MouseModifiers modifiers,
Subitem subitem,
java.awt.Point subitemPt,
java.awt.Point screenPt)
Perform a drag action against the associated TestObject.
|
void |
dragToScreenPoint(Subitem subitem,
java.awt.Point screenPt)
Perform a MOUSE_LEFT drag action against the associated TestObject.
|
void |
dragToScreenPoint(Subitem subitem,
java.awt.Point subitemPt,
java.awt.Point screenPt)
Perform a MOUSE_LEFT drag action against the associated TestObject.
|
IChannel |
getChannel()
return the channel for the object.
|
java.util.Enumeration |
getChildrenEnumeration()
PaletteRoot has no children.
|
MethodSpecification |
getDataDrivableCommand()
This method must be implemented by any proxy that wishes to support
data driving.
|
java.lang.String |
getDescriptiveName()
Return the descriptive name for the paletteRoot
|
java.util.Enumeration |
getImmediateChildren()
PaletteRoot has no children.
|
ProxyTestObject |
getMappableParent()
Return the mappable parent for the palette Root.
|
java.lang.Object |
getPaletteEntryAtPoint(java.awt.Point pt)
Finds the child object that is at the specified point.
|
ProxyTestObject |
getParent()
Return the Proxy of the palette Root's parent.
|
java.lang.Object |
getParentObject()
Return the parent of palette Root.
|
java.util.Hashtable |
getProperties()
Returns a complete set of properties for the associated
test object.
|
java.lang.Object |
getProperty(java.lang.String propertyName)
Gets the value for a specific property.
|
java.lang.String |
getRole()
Returns a brief type name that describes the role this object plays in the
UI.
|
java.awt.Rectangle |
getScreenRectangle()
Returns the rectangle that contains the component being
evaluated relative to the top left corner of the screen.
|
java.util.Hashtable |
getStandardProperties()
Returns a complete set of consistent properties for the associated
test object.
|
ITestData |
getTestData(java.lang.String testDataType)
This method constructs the specified verification data object.
|
java.util.Hashtable |
getTestDataTypes()
Returns a hashtable of data type descriptions of the verification
point data available with the associated object in the SUT.
|
java.lang.String |
getTestObjectClassName()
Return the test object class name for the palette proxy
|
boolean |
hasFocus()
Return true if the palette Root has focus.
|
void |
hover(double secondDelay,
Subitem subitem)
Hover the mouse over the center of the specified subitem.
|
void |
hover(double secondDelay,
Subitem subitem,
java.awt.Point pt)
Hover the mouse over the specified coordinates relative to the
specified subitem.
|
void |
hover(Subitem subitem)
Hover the mouse over the center of the specified subitem.
|
void |
hover(Subitem subitem,
java.awt.Point pt)
Hover the mouse over the specified coordinates relative to the
specified subitem.
|
boolean |
isEnabled()
Return true if the palette Root is enabled
|
boolean |
isPointInObject(java.awt.Point pt)
Determines if the specified screen relative point is
contained in the component under evaluation.
|
protected boolean |
isPointInPaletteArea(java.awt.Point pt)
Return true if the given point is in the palette Root
|
boolean |
isShowing()
Return true, as the palette root is visible
|
void |
mouseMove(MouseModifiers modifiers,
Subitem subitem)
Perform a move action against the associated TestObject.
|
void |
mouseMove(MouseModifiers modifiers,
Subitem subitem,
java.awt.Point pt)
Perform a move action against the associated TestObject.
|
void |
mouseMove(Subitem subitem)
Perform a MOUSE_LEFT move action against the associated TestObject.
|
void |
mouseMove(Subitem subitem,
java.awt.Point subitemPt)
Perform a MOUSE_LEFT move action against the associated TestObject.
|
void |
nClick(int clickCount,
MouseModifiers modifiers,
Subitem subitem,
java.awt.Point pt)
Perform a mouse n-click action on the specified coordinates relative
to the associated TestObject.
|
void |
nClickDrag(int clickCount,
MouseModifiers modifiers,
Subitem subitem1,
java.awt.Point pt1,
Subitem subitem2,
java.awt.Point pt2)
Perform a mouse n-click drag action on the specified coordinates relative
to the associated TestObject.
|
void |
nClickDrag(int clickCount,
MouseModifiers modifiers,
Subitem subitem1,
Subitem subitem2)
Perform a mouse n-click drag action on the specified coordinates relative
to the associated TestObject.
|
void |
nClickDragToScreenPoint(int clickCount,
MouseModifiers modifiers,
Subitem subitem,
java.awt.Point screenPt)
Perform a mouse n-click drag action on the specified coordinates relative
the screen relative screenPt coordinates.
|
void |
nClickDragToScreenPoint(int clickCount,
MouseModifiers modifiers,
Subitem subitem,
java.awt.Point subitemPt,
java.awt.Point screenPt)
Perform a mouse n-click drag action on the specified coordinates relative
the screen relative screenPt coordinates.
|
void |
processSingleMouseEvent(IMouseActionInfo action)
Proces the single click and determine the method specification needed
|
void |
select(java.lang.String text)
Select the palette Entry for the corresponding text.
|
boolean |
shouldBeMapped()
Returns true if the palette is enabled and is also visible
|
click, doubleClick, drag, dragToScreenPoint, dumpAction, ensureObjectIsVisible, getActionRect, getCachedRectX, getCachedRectY, getChildAtPoint, getClippedRect, getClippedScreenRectangle, getMethodSpecForPoint, getProcessMouseEventHandler, getRegisteredTopLevelWindow, getScreenPoint, getScreenPoint, getScriptCommandFlags, getTopMappableWindow, getTopWindow, hover, invokeMethodOnEDT, isDrag, isOpaque, isPointInObject, modifiersChanged, nClick, processHoverMouseEvent, processMouseEvent, scrollRectToVisible, setProcessMouseEventHandler, setTopLevelWindow
addMappableChildrenToVector, addRecognitionProperty, allowProperty, childConstructed, getAddedRecognitionPropertyValue, getChildren, getIndexer, getIndexers, getMappableChildren, getMethods, getNonValueProperties, getOwnedObjects, getOwner, getRecognitionProperties, getRecognitionPropertyWeight, getTestDomain, getTopMappableParent, getTopParent, getUniqueId, getVisualClippableParent, hasAddedRecognitionProperties, isRecognitionProperty, setIndexer, setProperty
addDataDrivableCommands, baseClassMatch, canTakeVP, equals, findChildrenWithProperties, findChildrenWithPropertiesAndInvoke, getChildren, getDataDrivableCommands, getElementWithFocus, getField, getIgnorableProperties, getMappableChildren, getMappableParent, getObjectClassName, getObjectCustomClassName, getOwnedObjects, getParent, getProxy, getScriptCommandAnchor, getVisualClippedRectangle, getVisualMappableChildren, getVisualTopParent, getVOMSpecificProperty, hasSpecialFrameState, isClassIndexConsidered, isSameObject, isValidObject, ping, suppressKeyAction, updateTestData
public PaletteProxy(java.lang.Object theObjectInTheSUT)
theObjectInTheSUT
- public java.awt.Rectangle getScreenRectangle()
getScreenRectangle
in class JavaGuiProxy
public boolean shouldBeMapped()
shouldBeMapped
in class JavaGuiProxy
public java.util.Enumeration getImmediateChildren()
getImmediateChildren
in class JavaGuiProxy
public java.util.Enumeration getChildrenEnumeration()
getChildrenEnumeration
in class JavaGuiProxy
public boolean isShowing()
isShowing
in class JavaGuiProxy
public java.lang.String getDescriptiveName()
getDescriptiveName
in class JavaGuiProxy
public ProxyTestObject getMappableParent()
getMappableParent
in class JavaGuiProxy
public ProxyTestObject getParent()
getParent
in class JavaGuiProxy
public java.lang.Object getParentObject()
getParentObject
in class JavaGuiProxy
public boolean hasFocus()
hasFocus
in class JavaGuiProxy
public boolean isEnabled()
isEnabled
in class JavaGuiProxy
public IChannel getChannel()
getChannel
in class ProxyTestObject
public java.lang.Object getProperty(java.lang.String propertyName)
getProperty
in class JavaProxy
propertyName
- The name of the property to fetch.ProxyTestObject.getProperties()
,
ProxyTestObject.setProperty(String,Object)
,
ProxyTestObject.getRecognitionProperties()
,
ProxyTestObject.addRecognitionProperty(String,Object,int)
public java.util.Hashtable getProperties()
This method does not return properties whose values are references
to objects. The method JavaProxy.getNonValueProperties()
returns
information about such properties.
getProperties
in class JavaProxy
getProperty(String)
,
JavaProxy.setProperty(String,Object)
,
getStandardProperties()
,
JavaProxy.getNonValueProperties()
public java.util.Hashtable getStandardProperties()
getProperties()
.
The HTML domain supports standard properties and
returns properties that are consistent across browser versions.
The Java domain does not support this notion of standard properties.
In this domain, getStandardProperties,
and getProperties
do the same thing.
For HTML, standard properties are a subset
of the properties returned by getProperties()
.
The meaning of a property is specific to the test domain
and the test object. Typically, this is a set of name/value pairs
that describe the test object and its active state. Properties such
as font, colors, and coordinate information are typically associated
with a GUI test object. Associated data and state information can also
be returned, depending on the test object.getStandardProperties
in class JavaProxy
getProperty(String)
,
JavaProxy.setProperty(String,Object)
,
getProperties()
,
JavaProxy.getNonValueProperties()
public void activateTopWindow()
activateTopWindow
in class JavaGuiProxy
public void activateTopWindow(java.lang.Object paletteEntry)
paletteEntry
- public java.util.Hashtable getTestDataTypes()
getTestDataTypes
in class JavaProxy
getTestData(String)
,
ITestData
public ITestData getTestData(java.lang.String testDataType)
getTestDataTypes
.getTestData
in class ProxyTestObject
testDataType
- A test data type supplied by
getTestDataTypes
.getTestDataTypes()
,
ITestData
public java.lang.String getRole()
ProxyTestObject
java.awt.Button
might return button.
There are suggested role constants in the TestObjectRole
class. However, proxies are not limited to these constants.
The role is used for several purposes by the test infrastructure. First, the
role can be used in the construction of object names in scripts, augmenting
the name returned by getDescriptiveName()
.
The role is also used in the UI to decorate nodes in the map with icons that
help users quickly associate the nodes with the roles they play in the system
under test.
public java.lang.Object getPaletteEntryAtPoint(java.awt.Point pt)
If this object has no children, it should return null
.
pt
- Screen relative point to check.getScreenRectangle()
public void processSingleMouseEvent(IMouseActionInfo action)
processSingleMouseEvent
in class JavaGuiProxy
protected boolean isPointInPaletteArea(java.awt.Point pt)
pt
- public boolean isPointInObject(java.awt.Point pt)
This functionality is performed by the proxy due to potentially
unusual aspects associated with functionality. While typically
the getScreenRectangle
is
used to resolve this query, there are situations for which this
is not accurate. For instance if the clickable region on a
button is not rectangular, just checking if the point is in
the rectangle is not be valid.
isPointInObject
in class JavaGuiProxy
pt
- Screen relative point to check.getScreenRectangle()
public void select(java.lang.String text)
text
- public void click(Subitem subitem)
click
in class JavaGuiProxy
public void click(MouseModifiers modifiers, Subitem subitem)
click
in class JavaGuiProxy
public void click(Subitem subitem, java.awt.Point pt)
click
in class JavaGuiProxy
public void click(MouseModifiers modifiers, Subitem subitem, java.awt.Point pt)
public void doubleClick(Subitem subitem)
doubleClick
in class JavaGuiProxy
public void doubleClick(MouseModifiers modifiers, Subitem subitem)
doubleClick
in class JavaGuiProxy
public void doubleClick(Subitem subitem, java.awt.Point pt)
doubleClick
in class JavaGuiProxy
public void doubleClick(MouseModifiers modifiers, Subitem subitem, java.awt.Point pt)
public void nClick(int clickCount, MouseModifiers modifiers, Subitem subitem, java.awt.Point pt)
public void drag(Subitem subitem)
drag
in class JavaGuiProxy
public void drag(MouseModifiers modifiers, Subitem subitem)
drag
in class JavaGuiProxy
public void drag(Subitem subitem1, Subitem subitem2)
drag
in class JavaGuiProxy
public void drag(MouseModifiers modifiers, Subitem subitem1, Subitem subitem2)
drag
in class JavaGuiProxy
public void drag(Subitem subitem1, java.awt.Point pt1, Subitem subitem2, java.awt.Point pt2)
public void drag(MouseModifiers modifiers, Subitem subitem1, java.awt.Point pt1, Subitem subitem2, java.awt.Point pt2)
public void nClickDrag(int clickCount, MouseModifiers modifiers, Subitem subitem1, Subitem subitem2)
nClickDrag
in class JavaGuiProxy
public void nClickDrag(int clickCount, MouseModifiers modifiers, Subitem subitem1, java.awt.Point pt1, Subitem subitem2, java.awt.Point pt2)
public void dragToScreenPoint(Subitem subitem, java.awt.Point screenPt)
dragToScreenPoint
in class JavaGuiProxy
public void dragToScreenPoint(MouseModifiers modifiers, Subitem subitem, java.awt.Point screenPt)
dragToScreenPoint
in class JavaGuiProxy
public void dragToScreenPoint(Subitem subitem, java.awt.Point subitemPt, java.awt.Point screenPt)
dragToScreenPoint
in class JavaGuiProxy
public void dragToScreenPoint(MouseModifiers modifiers, Subitem subitem, java.awt.Point subitemPt, java.awt.Point screenPt)
public void nClickDragToScreenPoint(int clickCount, MouseModifiers modifiers, Subitem subitem, java.awt.Point screenPt)
nClickDragToScreenPoint
in class JavaGuiProxy
public void nClickDragToScreenPoint(int clickCount, MouseModifiers modifiers, Subitem subitem, java.awt.Point subitemPt, java.awt.Point screenPt)
public void mouseMove(Subitem subitem)
mouseMove
in class JavaGuiProxy
public void mouseMove(Subitem subitem, java.awt.Point subitemPt)
mouseMove
in class JavaGuiProxy
public void mouseMove(MouseModifiers modifiers, Subitem subitem)
mouseMove
in class JavaGuiProxy
public void mouseMove(MouseModifiers modifiers, Subitem subitem, java.awt.Point pt)
public void hover(double secondDelay, Subitem subitem)
hover
in class JavaGuiProxy
public void hover(double secondDelay, Subitem subitem, java.awt.Point pt)
public void hover(Subitem subitem)
hover
in class JavaGuiProxy
public void hover(Subitem subitem, java.awt.Point pt)
hover
in class JavaGuiProxy
public java.lang.String getTestObjectClassName()
getTestObjectClassName
in interface IProxyBase
getTestObjectClassName
in class JavaGuiProxy
public MethodSpecification getDataDrivableCommand()
null
value is returned.getDataDrivableCommand
in interface IDataDriven
getDataDrivableCommand
in class ProxyTestObject
#getDataDrivableCommands()