public class JListProxy extends JScrollPaneProxy implements com.rational.test.ft.object.interfaces.ISubitem
javax.swing.JList class.
SelectGuiSubitemTestObject
| Type | Desciption | Data Class |
|---|---|---|
| list | List Elements | ITestDataList |
| selected | Selected List Elements | ITestDataList |
| Property | Usage |
|---|---|
| .class | The Java full class name of the test object. |
| .classIndex | The zero-based index of the class relative to the immediate parent in the object map. |
| .itemCount | The number of items in the list. |
| .itemText | The text for the up to ten items from the list. |
| .priorLabel | The text of a preceding label. Suppressed if there is no preceding label. |
| accessibleContext.accessibleName | A programmatically defined name for the component. |
| name | The name property, suppressed if default formatted (default form = className+count). |
| toolTipText | The text from the associated tool tip, omitted if there is no associated tool tip. |
| Subitem | Usage |
|---|---|
Text |
Defines the element with the specified visible text. |
Index |
Defines the element at the specified zero-based index. |
ComponentProxy.ChildEnumerator, ComponentProxy.ImmediateChildEnumeratortheScrollBarTAB_INDEX, TAB_TEXTchildrenEnumerated, CLASSINDEX, CLASSINDEXWEIGHT, MAX_NAME, NAMEPROPERTY, NAMEPROPERTYWEIGHT, PRIORLABEL, PRIORLABELWEIGHTLEFT, preDownState, processMouseEventHandler, ROLEINDEX, ROLEINDEXWEIGHT, TESTDATA_SPECIALFRAMESTATE, TESTDATA_SPECIALFRAMESTATE_DESCRIPTION, topLevelWindowBROWSERTABTESTOBJECT_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| Constructor and Description |
|---|
JListProxy(java.lang.Object theObjectInTheSUT)
This sole constructor for all proxy objects sets the SUT object
as a member variable for the proxy.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
canBeScrolled()
Returns true if the object is associated with scrollbar(s).
|
protected void |
deselect(int item)
This method deselects a subitem at a specified index.
|
protected void |
deselectAll()
Deselects all the selected items.
|
protected void |
ensureIndexIsVisible(int index)
If this JList is being displayed within a JViewport and the specified cell
isn't completely visible, scroll the viewport to make this cell visible.
|
protected void |
extendSelect(int item)
This method extends the current selection to include
a subitem at a specified index.
|
protected int |
getAdjustedLastVisibleIndex() |
protected java.lang.String[] |
getAllText(int limit) |
protected java.awt.Rectangle |
getCellBounds(int index0,
int index1)
Returns the bounds of the specified range of items in JList coordinates.
|
com.rational.test.ft.sys.MethodSpecification |
getDataDrivableCommand()
This method must be implemented by any proxy that wishes to support
data driving.
|
protected int |
getFirstSelectedIndex() |
protected int |
getFirstVisibleIndex()
Returns the index of the cell in the upper left corner of the JList
or -1 if nothing is visible or the list is empty.
|
protected int |
getItemCount() |
protected int |
getItemIndex(java.lang.String item)
Returns the index in the JList of item .
|
protected int |
getItemIndex(com.rational.test.ft.script.Subitem item)
Returns the index in the JList of item.
|
protected int |
getItemIndex(com.rational.test.ft.script.Text item)
Returns the index in the JList of item.
|
protected java.lang.String |
getItemText(int index)
Returns the value at the specified index.
|
protected int |
getLastVisibleIndex()
Returns the index of the cell in the lower left corner of the JList
or -1 if nothing is visible or the list is empty.
|
com.rational.test.ft.domain.ProxyTestObject[] |
getMappableChildren()
Uses getChildren to implement.
|
com.rational.test.ft.sys.MethodSpecification |
getMethodSpecForPoint(java.awt.Point pt)
Return a MethodSpecification for a method that returns a java.awt.Point
for the specified coordinates.
|
protected javax.swing.ListModel |
getModel()
Returns the data model that holds the list of items displayed by the JList component.
|
protected java.lang.Object |
getObjectAtIndex(int index) |
com.rational.test.ft.domain.ProxyTestObject |
getOwner()
Returns a proxy object for the owner of this object.
|
java.util.Hashtable |
getProperties() |
java.lang.Object |
getProperty(java.lang.String propertyName)
Get the value for a specific property.
|
java.lang.String |
getRole()
Returns
TestObjectRole.ROLE_LIST. |
java.awt.Rectangle |
getScreenRectangle(com.rational.test.ft.script.Subitem subitem)
Returns the rectangle that contains the component being
evaluated relative to the top left corner of the screen.
|
protected int[] |
getSelectedIndices() |
protected java.lang.String[] |
getSelectedItems() |
protected java.lang.Object[] |
getSelectedTestDataObjects() |
java.lang.String |
getSelectedText()
Allows direct access to the selected text property on the control.
|
protected com.rational.test.ft.script.Subitem |
getSubitem(int index)
Returns the Subitem at the specified index.
|
java.lang.Object |
getSubitem(com.rational.test.ft.script.Subitem subitem)
Returns an object that represents the specified subitem in the associated
test object.
|
com.rational.test.ft.vp.ITestData |
getTestData(java.lang.String testDataType)
This method constructs the specified verification data object.
|
protected java.lang.Object[] |
getTestDataObjects() |
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 ListTestObject classname, the default JList test object.
|
java.lang.String |
getText()
Allows direct access to the text property on the control.
|
protected boolean |
isSelectedIndex(int index)
Returns true if the specified index is selected.
|
protected int |
locationToIndex(java.awt.Point currentPoint)
Returns the origin of the specified item in JList coordinates.
|
void |
processSingleMouseEvent(com.rational.test.ft.domain.IMouseActionInfo action)
Return a MethodSpecification for the specified mouse event.
|
void |
select(int item) |
void |
select(java.lang.String item) |
protected void |
selectProgrammatically(int item)
This method selects a subitem at a specified index.
|
void |
setProperty(java.lang.String propertyName,
java.lang.Object value)
Sets the value for a specific property.
|
void |
setState(com.rational.test.ft.script.Action action)
This method performs a specific action.
|
protected void |
setState(com.rational.test.ft.script.Action action,
int item)
This method performs a specific action against the subitem
at a specified index.
|
void |
setState(com.rational.test.ft.script.Action action,
com.rational.test.ft.script.Subitem item)
This method performs a specific action against the subitem
at a specified index.
|
void |
setState(com.rational.test.ft.script.Action action,
com.rational.test.ft.script.Subitem start,
com.rational.test.ft.script.Subitem end)
This method performs a specific action against the subitem
range defined by the specified indices.
|
boolean |
shouldBeMapped()
Returns true for JListProxy.
|
com.rational.test.ft.vp.ITestData |
updateTestData(java.lang.String testDataType,
com.rational.test.ft.vp.ITestData testData)
This method updates the supplied test data object and returns it.
|
click, getAssociateProxy, getClippedRect, getHScroll, getRealTestObject, getScroll, getScrollPaneProxy, getViewport, getVScroll, isPointInObject, isScrollclick, click, click, doubleClick, doubleClick, doubleClick, doubleClick, drag, drag, drag, drag, drag, drag, dragToScreenPoint, dragToScreenPoint, dragToScreenPoint, dragToScreenPoint, getScreenPoint, getScreenPoint, hover, hover, hover, hover, mouseMove, mouseMove, mouseMove, mouseMove, nClick, nClickDrag, nClickDrag, nClickDragToScreenPoint, nClickDragToScreenPointgetBorderTitle, getClippedScreenRectangle, getDescriptiveName, getStandardProperties, getText, getVisibleRectangle, getVisualClippedRectangle, hasFocus, isOpaque, isType, scrollRectToVisiblechildConstructed, getChildAtPoint, getChildProxy, getChildrenEnumeration, getComponentChildren, getElementWithFocus, getEmbeddedBrowsers, getImmediateChildren, getLabelText, getLeadingLabel, getLocationOnScreen, getMappableParent, getName, getOwnedObjects, getParent, getParent2, getParentObject, getScreenRectangle, getTopParent, getWindow, isDopeyDynamicName, isEnabled, isHScroll, isLabelled, isRecognitionProperty, isShowing, isVScroll, setParentactivateTopWindow, click, click, click, click, doubleClick, doubleClick, doubleClick, doubleClick, drag, drag, drag, drag, dragToScreenPoint, dragToScreenPoint, dragToScreenPoint, dumpAction, ensureObjectIsVisible, getActionRect, getCachedRectX, getCachedRectY, getProcessMouseEventHandler, getRegisteredTopLevelWindow, getScreenPoint, getScreenPoint, getScriptCommandFlags, getTopMappableWindow, getTopWindow, hover, hover, hover, hover, invokeMethodOnEDT, isDrag, isPointInObject, modifiersChanged, mouseMove, mouseMove, nClick, nClickDrag, nClickDragToScreenPoint, processHoverMouseEvent, processMouseEvent, setProcessMouseEventHandler, setTopLevelWindowaddMappableChildrenToVector, addRecognitionProperty, allowProperty, getAddedRecognitionPropertyValue, getChildren, getIndexer, getIndexers, getMethods, getNonValueProperties, getRecognitionProperties, getRecognitionPropertyWeight, getTestDomain, getTopMappableParent, getUniqueId, getVisualClippableParent, hasAddedRecognitionProperties, setIndexeraddDataDrivableCommands, baseClassMatch, canTakeVP, equals, findChildrenWithProperties, findChildrenWithPropertiesAndInvoke, getChannel, getChildren, getDataDrivableCommands, getField, getIgnorableProperties, getMappableChildren, getMappableParent, getObjectClassName, getObjectCustomClassName, getOwnedObjects, getParent, getProxy, getScriptCommandAnchor, getVisualMappableChildren, getVisualTopParent, getVOMSpecificProperty, hasSpecialFrameState, isClassIndexConsidered, isSameObject, isValidObject, ping, suppressKeyActionpublic JListProxy(java.lang.Object theObjectInTheSUT)
public java.lang.String getTestObjectClassName()
getTestObjectClassName in interface com.rational.test.ft.domain.IProxyBasegetTestObjectClassName in class JfcGraphicalSubitemProxypublic java.util.Hashtable getProperties()
getProperties in class JComponentProxypublic java.lang.Object getProperty(java.lang.String propertyName)
getProperty in class JComponentProxypublic void setProperty(java.lang.String propertyName,
java.lang.Object value)
JavaProxysetProperty in class JavaProxypublic com.rational.test.ft.domain.ProxyTestObject[] getMappableChildren()
getMappableChildren in class ComponentProxypublic com.rational.test.ft.domain.ProxyTestObject getOwner()
getOwner in class ComponentProxypublic java.lang.String getRole()
TestObjectRole.ROLE_LIST.getRole in class JScrollPaneProxypublic boolean shouldBeMapped()
shouldBeMapped in class JScrollPaneProxyprotected int locationToIndex(java.awt.Point currentPoint)
index - the index of the JList cellprotected int getFirstVisibleIndex()
protected int getLastVisibleIndex()
protected int getAdjustedLastVisibleIndex()
protected java.awt.Rectangle getCellBounds(int index0,
int index1)
index0 - the index of the first JList cell in the range
index1 the index of the last JList cell in the rangeprotected javax.swing.ListModel getModel()
protected boolean isSelectedIndex(int index)
index - index to be queried for selection stateprotected java.lang.String[] getSelectedItems()
protected java.lang.Object[] getSelectedTestDataObjects()
protected int[] getSelectedIndices()
protected int getFirstSelectedIndex()
protected java.lang.String getItemText(int index)
index - the specified index.protected int getItemCount()
protected java.lang.Object getObjectAtIndex(int index)
protected java.lang.Object[] getTestDataObjects()
protected java.lang.String[] getAllText(int limit)
protected com.rational.test.ft.script.Subitem getSubitem(int index)
index - the specified index.protected int getItemIndex(java.lang.String item)
item - a Stringprotected int getItemIndex(com.rational.test.ft.script.Text item)
item - a Textprotected int getItemIndex(com.rational.test.ft.script.Subitem item)
item - a Subitempublic java.lang.Object getSubitem(com.rational.test.ft.script.Subitem subitem)
SubitemNotFoundException
will be thrown if the specified subitem is invalid relative to the associated
test object. null may be returned if the subitem does not have
an object association that can be returned.getSubitem in interface com.rational.test.ft.object.interfaces.IGraphicalSubitemgetSubitem in class JScrollPaneProxysubitem - The subitem to fetch an object for.protected void ensureIndexIsVisible(int index)
index - the index of the cell to make visiblepublic java.lang.String getSelectedText()
public java.lang.String getText()
protected void deselectAll()
public void select(java.lang.String item)
public void select(int item)
protected void selectProgrammatically(int item)
item - The index of the item to select.protected void deselect(int item)
item - The index of the item to deselect.protected void extendSelect(int item)
item - The index of the item to select.protected void setState(com.rational.test.ft.script.Action action,
int item)
item - The index of the item to act upon.action - The action that should be performed.public void setState(com.rational.test.ft.script.Action action)
setState in interface com.rational.test.ft.object.interfaces.ISubitemsetState in class JScrollPaneProxyaction - The action that should be performed.public void setState(com.rational.test.ft.script.Action action,
com.rational.test.ft.script.Subitem item)
setState in interface com.rational.test.ft.object.interfaces.ISubitemsetState in class JScrollPaneProxyitem - The item to act upon.action - The action that should be performed.public void setState(com.rational.test.ft.script.Action action,
com.rational.test.ft.script.Subitem start,
com.rational.test.ft.script.Subitem end)
setState in interface com.rational.test.ft.object.interfaces.ISubitemsetState in class JScrollPaneProxystart - The first item to act upon.end - The last item to act upon.action - The action that should be performed.public com.rational.test.ft.sys.MethodSpecification getDataDrivableCommand()
null value is returned.getDataDrivableCommand in interface com.rational.test.ft.domain.IDataDrivengetDataDrivableCommand in class com.rational.test.ft.domain.ProxyTestObjectProxyTestObject.getDataDrivableCommands(int)public void processSingleMouseEvent(com.rational.test.ft.domain.IMouseActionInfo action)
processSingleMouseEvent in class JavaGuiProxyaction - The event cache and other mouse state information
for this mouse action.public com.rational.test.ft.sys.MethodSpecification getMethodSpecForPoint(java.awt.Point pt)
IGraphical.getScreenPoint will be returned. However, if a proxy can findgetMethodSpecForPoint in class JavaGuiProxyx - The screen relative x coordinate.y - The screen relative y coordinate.MethodSpecificationpublic java.awt.Rectangle getScreenRectangle(com.rational.test.ft.script.Subitem subitem)
getScreenRectangle in interface com.rational.test.ft.object.interfaces.IGraphicalSubitemgetScreenRectangle in class JScrollPaneProxypublic java.util.Hashtable getTestDataTypes()
getTestDataTypes in class JavaProxygetTestData(String),
ITestDatapublic com.rational.test.ft.vp.ITestData getTestData(java.lang.String testDataType)
getTestDataTypes.getTestData in class com.rational.test.ft.domain.ProxyTestObjecttestDataType - A test data type supplied by
getTestDataTypes.getTestDataTypes(),
ITestDatapublic com.rational.test.ft.vp.ITestData updateTestData(java.lang.String testDataType,
com.rational.test.ft.vp.ITestData testData)
getTestDataTypes.
The testData is a previously supplied ITestData
object that needs to be updated to reflect the current state
of the associated test object.updateTestData in class com.rational.test.ft.domain.ProxyTestObjecttestDataType - A test data type supplied by
getTestDataTypes.testData - The test data base object that requires
updating.getTestDataTypes(),
ITestDatapublic boolean canBeScrolled()
canBeScrolled in class ComponentProxy