|
IBM Rational Functional Tester Version 8.1.1000 IBM Rational Functional Tester Proxy SDK Reference Project Version 2.3 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.rational.test.ft.sys.RegisteredObject com.rational.test.ft.domain.ProxyTestObject com.rational.test.ft.domain.DescribedObjectReference
public class DescribedObjectReference
DescribedObjectReference represents the reference to a DescribedObject, an known object which exists in another domain. The reference is a list of properties stored in a SpyMap. This class is derived from ProxyTestObject so that it may be returned in methods which normally return a proxy, such as getParent/getChildren.
Field Summary | |
---|---|
static java.lang.String |
PARENT_PROCESS_WINDOW
|
static java.lang.String |
PROCESSID
|
static java.lang.String |
TARGETDOMAIN
|
static java.lang.String |
TARGETSUBDOMAIN
|
static java.lang.String |
THREADID
|
static java.lang.String |
WINDOW
|
Fields inherited from class com.rational.test.ft.sys.RegisteredObject |
---|
theTestObject |
Fields inherited from interface com.rational.test.ft.domain.IDataDriven |
---|
INCLUDE_ALL, INCLUDE_JUSTOBJECT, INCLUDE_SIBLINGS |
Constructor Summary | |
---|---|
DescribedObjectReference()
|
|
DescribedObjectReference(com.rational.test.ft.sys.HashtableEx propertyMap)
|
|
DescribedObjectReference(com.rational.test.ft.sys.HashtableEx propertyMap, java.lang.String testObjectClassname)
|
|
DescribedObjectReference(java.lang.String testObjectClassname)
|
Method Summary | |
---|---|
void |
addRecognitionProperty(java.lang.String propertyName, java.lang.Object val, int weight)
Defines an additional recognition property that this proxy can use. |
boolean |
equals(java.lang.Object obj)
Overrides the object-level equals with an equality against the true test objects. |
ProxyTestObject[] |
getChildren()
Returns an array of proxies, visible by using the TestObject interface from a script, for the children of this object. |
java.lang.String |
getDescriptiveName()
Returns a name that can be used to describe the associated UI object in a script. |
com.rational.test.ft.object.manager.FindPropertySet |
getFindProperties()
|
java.lang.Object |
getIndexer(java.lang.String name, java.lang.Object[] indexes)
Gets the value of an indexed property |
com.rational.test.ft.value.IndexerInfo[] |
getIndexers()
Gets information about a TestObject's indexed properties |
ProxyTestObject[] |
getMappableChildren()
Returns an array of proxies, visible by using the TestObject interface from a script, for the children of this object. |
ProxyTestObject |
getMappableParent()
Returns a proxy object for the mappable parent of this object; returns null if this object has no mappable parent. |
com.rational.test.ft.value.MethodInfo[] |
getMethods()
Returns an array containing method signatures for all methodsaccessiblee against the associated test object. |
com.rational.test.ft.sys.MethodSpecification |
getMethodSpecForPoint(java.awt.Point pt)
Returns a MethodSpecification for a method that returns a java.awt.Point
for the specified coordinates. |
java.util.Hashtable |
getNonValueProperties()
Returns the properties that are not supported because the value is a reference to another object. |
java.lang.Object |
getObject()
Export access to the object under evaluation in the SUT. |
ProxyTestObject[] |
getOwnedObjects()
Returns an array of proxies for the objects owned by this object. |
ProxyTestObject |
getOwner()
Returns a proxy object for the owner of this object; returns null if this object has no owner. |
ProxyTestObject |
getParent()
Returns a proxy object for the parent of this object; returns null if this object has no parent. |
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 defined in getProperties() or getRecognitionProperties() . |
com.rational.test.ft.sys.HashtableEx |
getPropertyMap()
|
com.rational.test.ft.sys.SpyMap |
getPropertySpyMap()
Convert the property map to a SpyMap. |
java.util.Hashtable |
getRecognitionProperties()
Returns an enumeration of properties used to identify the associated test object. |
int |
getRecognitionPropertyWeight(java.lang.String propertyName)
Returns an indication of how useful this property is for recognition. |
java.util.Hashtable |
getStandardProperties()
Returns a complete set of consistent properties for the associated test object. |
java.util.Hashtable |
getTestDataTypes()
Returns a hashtable of data type descriptions of the verification point data available with the associated object. |
TestDomainImplementation |
getTestDomain()
Returns the TestDomain that this proxy object is associated
with. |
java.lang.String |
getTestObjectClassName()
Returns a valid class name specification. |
ProxyTestObject |
getTopMappableParent()
Returns a proxy object for the top mappable parent of this object; returns a pointer to itself if this object has no mappable parent. |
ProxyTestObject |
getTopParent()
Returns a proxy object for the top parent of this object; returns a pointer to itself if this object has no parent. |
java.lang.String |
getUniqueId()
Returns a string for the associated object. |
boolean |
hasAddedRecognitionProperties()
Returns true if recognition properties have been added to this proxy from an external source through addRecognitionProperty() . |
boolean |
isReleaseRequired()
|
void |
processMouseEvent(IMouseActionInfo action)
Updates the supplied action with an appropriate MethodSpecification to play back the action. |
void |
release()
Override this to do cleanup - it is called when the object is no longer referenced. |
void |
setFindProperties(com.rational.test.ft.object.manager.FindPropertySet propSet)
|
void |
setIndexer(java.lang.String name, java.lang.Object[] indexes, java.lang.Object val)
Sets the value of an indexed property |
void |
setProperty(java.lang.String propertyName, java.lang.Object propertyValue)
Sets the value for a specific property defined in getProperties() or getRecognitionProperties() . |
boolean |
shouldBeMapped()
Determines whether the object is interesting from a persistent testability sense and should therefore be added to the object map. |
Methods inherited from class com.rational.test.ft.sys.RegisteredObject |
---|
addProxyReference, dereference, getRegisteredId, getTransactionId, isReferenced, register, registerTransiently, toString, unregister |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String PROCESSID
public static final java.lang.String THREADID
public static final java.lang.String WINDOW
public static final java.lang.String TARGETDOMAIN
public static final java.lang.String TARGETSUBDOMAIN
public static final java.lang.String PARENT_PROCESS_WINDOW
Constructor Detail |
---|
public DescribedObjectReference()
public DescribedObjectReference(java.lang.String testObjectClassname)
public DescribedObjectReference(com.rational.test.ft.sys.HashtableEx propertyMap)
public DescribedObjectReference(com.rational.test.ft.sys.HashtableEx propertyMap, java.lang.String testObjectClassname)
Method Detail |
---|
public com.rational.test.ft.sys.HashtableEx getPropertyMap()
public com.rational.test.ft.sys.SpyMap getPropertySpyMap()
public java.lang.Object getProperty(java.lang.String propertyName)
ProxyTestObject
getProperties()
or getRecognitionProperties()
. If the property is not defined by either of these methods, this method throws PropertyNotFoundException
.
getProperty
in class ProxyTestObject
propertyName
- The name of the property to fetch.
ProxyTestObject.getProperties()
,
ProxyTestObject.setProperty(String,Object)
,
ProxyTestObject.getRecognitionProperties()
,
ProxyTestObject.addRecognitionProperty(String,Object,int)
public void setProperty(java.lang.String propertyName, java.lang.Object propertyValue)
ProxyTestObject
getProperties()
or getRecognitionProperties()
. Properties not defined by either of these methods, and properties whose values cannot be modified throw an
appropriately populated PropertyNotFoundException
.
setProperty
in class ProxyTestObject
propertyName
- The name of the property to redefine. This name is the same as that returned by
getProperties()
.ProxyTestObject.getProperties()
,
ProxyTestObject.getProperty(String)
public void addRecognitionProperty(java.lang.String propertyName, java.lang.Object val, int weight)
ProxyTestObject
ProxyTestObject.getRecognitionProperties()
.
addRecognitionProperty
in class ProxyTestObject
propertyName
- The recognition property name. Care should be taken to avoid conflicts with existing property names.val
- The value of the added recognition property.weight
- The weight associated with this recognition property.
This value is returned when getRecognitionPropertyWeight()
is called.ProxyTestObject.getRecognitionProperties()
,
ProxyTestObject.getRecognitionPropertyWeight(String)
,
ProxyTestObject.getProperty(String)
public void setFindProperties(com.rational.test.ft.object.manager.FindPropertySet propSet)
public com.rational.test.ft.object.manager.FindPropertySet getFindProperties()
public java.util.Hashtable getNonValueProperties()
ProxyTestObject
getProperty()
.
If such a property is returned to the test script, it is manifested as a TestObject containing a reference to the object in the SUT. The test script should call the TestObject method unregister() to release the object.
When an object is unregistered, the release() method that all ProxyTestObjects inherit from RegisteredObject is called.
getNonValueProperties
in class ProxyTestObject
ProxyTestObject.getProperties()
,
ProxyTestObject.getStandardProperties()
,
ProxyTestObject.getProperty(String)
,
ProxyTestObject.setProperty(String,Object)
public java.lang.Object getIndexer(java.lang.String name, java.lang.Object[] indexes)
getIndexer
in class ProxyTestObject
name
- the name of the indexerindexes
- the indexes to get the value ofpublic com.rational.test.ft.value.IndexerInfo[] getIndexers()
TestObject's
indexed properties
getIndexers
in class ProxyTestObject
IndexerInfo
public void setIndexer(java.lang.String name, java.lang.Object[] indexes, java.lang.Object val)
setIndexer
in class ProxyTestObject
name
- the name of the indexerindexes
- the indexes to set the value ofpublic ProxyTestObject getMappableParent()
ProxyTestObject
null
if this object has no mappable parent.
Note that only a proxy that shouldBeMapped
should be returned from this method.
getMappableParent
in class ProxyTestObject
null
for a top-level mapped object.public ProxyTestObject[] getOwnedObjects()
ProxyTestObject
getOwnedObjects
in class ProxyTestObject
public ProxyTestObject getOwner()
ProxyTestObject
null
if this object has no owner.
getOwner
in class ProxyTestObject
null
for a top object without an owner.public ProxyTestObject getParent()
ProxyTestObject
null
if this object has no parent.
getParent
in class ProxyTestObject
null
for a top-level object.public java.util.Hashtable getProperties()
ProxyTestObject
This method does not return properties whose values are references to objects. The method ProxyTestObject.getNonValueProperties()
returns information about such properties.
getProperties
in class ProxyTestObject
ProxyTestObject.getProperty(String)
,
ProxyTestObject.setProperty(String,Object)
,
ProxyTestObject.getStandardProperties()
,
ProxyTestObject.getNonValueProperties()
public java.util.Hashtable getRecognitionProperties()
ProxyTestObject
hasFocus
or isShowing
.
getRecognitionProperties
in class ProxyTestObject
TestObjectProperty
.ProxyTestObject.getRecognitionPropertyWeight(String)
,
ProxyTestObject.getProperty(String)
,
ProxyTestObject.addRecognitionProperty(String,Object,int)
public int getRecognitionPropertyWeight(java.lang.String propertyName)
ProxyTestObject
getRecognitionPropertyWeight
in class ProxyTestObject
propertyName
- The name of the recognition property to
return a weight value for.ProxyTestObject.getRecognitionProperties()
public java.util.Hashtable getStandardProperties()
ProxyTestObject
ProxyTestObject.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 ProxyTestObject
ProxyTestObject.getProperty(String)
,
ProxyTestObject.setProperty(String,Object)
,
ProxyTestObject.getProperties()
,
ProxyTestObject.getNonValueProperties()
public java.util.Hashtable getTestDataTypes()
ProxyTestObject
String
objects that are used as the VP type
in the associated test data. The type
is a
simple value that is different from other type values associated with this object under test. The type
keys map to a verbose description of the test data, reasonable for presentation to a
user.
getTestDataTypes
in class ProxyTestObject
type
/description
pairs used to describe the verification data available from this proxy.ProxyTestObject.getTestData(String)
,
ITestData
public TestDomainImplementation getTestDomain()
ProxyTestObject
TestDomain
that this proxy object is associated
with.
getTestDomain
in interface IProxyBase
getTestDomain
in class ProxyTestObject
TestDomain
class full name.public ProxyTestObject getTopMappableParent()
ProxyTestObject
getTopMappableParent
in class ProxyTestObject
public ProxyTestObject getTopParent()
ProxyTestObject
getTopParent
in class ProxyTestObject
public java.lang.String getUniqueId()
ProxyTestObject
getUniqueId
in class ProxyTestObject
public boolean shouldBeMapped()
ProxyTestObject
false
.
shouldBeMapped
in class ProxyTestObject
true
if the represented control is interesting other than for nested objects.public boolean hasAddedRecognitionProperties()
ProxyTestObject
true
if recognition properties have been added to this proxy from an external source through addRecognitionProperty()
.
hasAddedRecognitionProperties
in class ProxyTestObject
true
if recognition properties have been added to this proxy from an external source through addRecognitionProperty(String,Object,int)
.ProxyTestObject.addRecognitionProperty(String,Object,int)
public void processMouseEvent(IMouseActionInfo action)
ProxyTestObject
action
with an appropriate MethodSpecification
to play back the action. This
method is the primary record interface for mouse events against a particular
control. Only one MethodSpecification
is maintained in the action state. If the active specification is valid, it is not updated.
processMouseEvent
in class ProxyTestObject
action
- The event cache and other mouse state information
for this mouse action.IMouseActionInfo
,
MethodSpecification
public boolean isReleaseRequired()
isReleaseRequired
in class com.rational.test.ft.sys.RegisteredObject
public void release()
com.rational.test.ft.sys.RegisteredObject
release
in class com.rational.test.ft.sys.RegisteredObject
public boolean equals(java.lang.Object obj)
ProxyTestObject
equals
with an equality against the true test objects.
equals
in class ProxyTestObject
obj
- The object to compare against. If obj
is a ProxyTestObject
, the comparison is made with the underlying object.
true
if the underlying test objects are equal
.public ProxyTestObject[] getChildren()
ProxyTestObject
getChildren
in class ProxyTestObject
public java.lang.String getDescriptiveName()
ProxyTestObject
java.awt.Button
with the associated text "OK".
getDescriptiveName
in class ProxyTestObject
public ProxyTestObject[] getMappableChildren()
ProxyTestObject
getMappableChildren
in class ProxyTestObject
public com.rational.test.ft.value.MethodInfo[] getMethods()
ProxyTestObject
getMethods
in class ProxyTestObject
ProxyTestObject.getProperties()
,
ProxyTestObject.getStandardProperties()
,
ProxyTestObject.getNonValueProperties()
public com.rational.test.ft.sys.MethodSpecification getMethodSpecForPoint(java.awt.Point pt)
ProxyTestObject
MethodSpecification
for a method that returns a java.awt.Point
for the specified coordinates. By default, a method specification for IGraphical.getScreenPoint
is returned.
getMethodSpecForPoint
in class ProxyTestObject
MethodSpecification
public java.lang.String getTestObjectClassName()
ProxyTestObject
TestObject
class. The testObject
performs a cross-process (and cross-JVM) call to the same method against an associated proxy, which is this proxy.
This method should never return null
, even if shouldBeMapped()
returns false
. User may still access objects such as this through scripting method calls and can return references to them.
If a null were returned, the marshalling code would be confused and would not be able to construct a test object.
This method may be called from any thread.
getTestObjectClassName
in interface IProxyBase
getTestObjectClassName
in class ProxyTestObject
testObject
class full name.public java.lang.Object getObject()
com.rational.test.ft.sys.RegisteredObject
getObject
in class com.rational.test.ft.sys.RegisteredObject
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |