TPTP 4.4.0 Testing Tools Project
Internal API Specification

org.eclipse.tptp.test.auto.gui.internal.macro
Class UIObject

java.lang.Object
  extended byorg.eclipse.tptp.test.auto.gui.internal.macro.UIObject
All Implemented Interfaces:
IUIObject

public class UIObject
extends java.lang.Object
implements IUIObject


Constructor Summary
UIObject(IUIObject parent)
           
 
Method Summary
 void addChild(IUIObject child)
          Adds a child to this object.
 void addProperty(java.lang.String name, java.lang.String value)
          Add a property to this UI object.
 int childCount()
          Returns the number of children that this UI object has
static IUIObject createInstance(IObjectMine objectMine, AbstractMacroCommand command, IUIObject parent)
          Creates an instace of this class based on a command passed in.
 IUIObject findChild(java.lang.String referenceId)
          Returns the child with a matching reference id passed in; null if none is found
 IUIObject[] getChildren()
          Returns the children of this UI object
 java.lang.String getContextId()
          Returns the context id of this object
 java.lang.Object getData()
          Returns the data associated with this object.
 java.lang.String getDescriptive()
          Returns the descriptive field of this object.
 java.util.LinkedList getHierarchicalRelation()
          Returns the hierarchical relationshipt of this object relative to its parents.
 java.lang.String getObjectId()
          Returns the id of this object.
 IUIObject getParent()
          Returns the parent of this UI object
 java.util.Map getProperties()
          Returns the properties of this UI object.
 java.lang.String getProperty(java.lang.String name)
          Returns the property of this object
 java.lang.String getReferenceId()
          Return the reference id of this object
 java.lang.String getResolverId()
          Returns the resolver id that has resolved this object
 IUIObject removeChild(IUIObject child)
          Removes a child from this object
 void setContextId(java.lang.String contextId)
          Sets the context id of this object
 void setData(java.lang.Object data)
          Can be used to associate a general data object with this object.
 void setDescriptive(java.lang.String descriptive)
          Returns the descriptive field of this object.
 void setObjectId(java.lang.String id)
          Sets the id of this object.
 void setParent(IUIObject parent)
          Set the parent of this UI object
 void setReferenceId(java.lang.String referenceId)
          Set the reference id of this object.
 void setResolver(java.lang.String resolverId)
          Sets the resolver id for this object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UIObject

public UIObject(IUIObject parent)
Method Detail

createInstance

public static IUIObject createInstance(IObjectMine objectMine,
                                       AbstractMacroCommand command,
                                       IUIObject parent)
Creates an instace of this class based on a command passed in.

Parameters:
objectMine - The object mine that this object will be registered with
command - The command that this object will be based on
parent - The parent of this object
Returns:
An instance of this class based on widgetIdentifier

getContextId

public java.lang.String getContextId()
Description copied from interface: IUIObject
Returns the context id of this object

Specified by:
getContextId in interface IUIObject
Returns:
The context id

getDescriptive

public java.lang.String getDescriptive()
Description copied from interface: IUIObject
Returns the descriptive field of this object. The descriptive field is human readable label that is used to easily recognize the object.

Specified by:
getDescriptive in interface IUIObject
Returns:
descriptive field

getHierarchicalRelation

public java.util.LinkedList getHierarchicalRelation()
Description copied from interface: IUIObject
Returns the hierarchical relationshipt of this object relative to its parents. A linked list is returned whose first element is the child of the root UI object node and its last node is this UI object. An object directly above a node is the parent of that node.

Specified by:
getHierarchicalRelation in interface IUIObject
Returns:
A linked list indicating the hierarchical relationship between this node and its parents.

getObjectId

public java.lang.String getObjectId()
Description copied from interface: IUIObject
Returns the id of this object. This is the id used by the playback operations to identify the UI object.

Specified by:
getObjectId in interface IUIObject
Returns:
object id

getProperties

public java.util.Map getProperties()
Description copied from interface: IUIObject
Returns the properties of this UI object.

Specified by:
getProperties in interface IUIObject
Returns:
The properties of this UI object

getProperty

public java.lang.String getProperty(java.lang.String name)
Description copied from interface: IUIObject
Returns the property of this object

Specified by:
getProperty in interface IUIObject
Parameters:
name - The name of the property.
Returns:
The value of the property with the name passed in. null is returned if the property can't be found.

getReferenceId

public java.lang.String getReferenceId()
Description copied from interface: IUIObject
Return the reference id of this object

Specified by:
getReferenceId in interface IUIObject
Returns:
reference id

setContextId

public void setContextId(java.lang.String contextId)
Description copied from interface: IUIObject
Sets the context id of this object

Specified by:
setContextId in interface IUIObject
Parameters:
contextId - The context id of this object

setDescriptive

public void setDescriptive(java.lang.String descriptive)
Description copied from interface: IUIObject
Returns the descriptive field of this object. The descriptive field is human readable label that is used to easily recognize the object.

Specified by:
setDescriptive in interface IUIObject
Parameters:
descriptive - field

setObjectId

public void setObjectId(java.lang.String id)
Description copied from interface: IUIObject
Sets the id of this object. This is the id used by the playback operations to identify the UI object.

Specified by:
setObjectId in interface IUIObject

addProperty

public void addProperty(java.lang.String name,
                        java.lang.String value)
Description copied from interface: IUIObject
Add a property to this UI object.

Specified by:
addProperty in interface IUIObject
Parameters:
name - The name of the property
value - The value of the property

setReferenceId

public void setReferenceId(java.lang.String referenceId)
Description copied from interface: IUIObject
Set the reference id of this object.

Specified by:
setReferenceId in interface IUIObject
Parameters:
referenceId - The reference id

getParent

public IUIObject getParent()
Description copied from interface: IUIObject
Returns the parent of this UI object

Specified by:
getParent in interface IUIObject
Returns:
The parent

setParent

public void setParent(IUIObject parent)
Description copied from interface: IUIObject
Set the parent of this UI object

Specified by:
setParent in interface IUIObject
Parameters:
parent - The parent

getResolverId

public java.lang.String getResolverId()
Description copied from interface: IUIObject
Returns the resolver id that has resolved this object

Specified by:
getResolverId in interface IUIObject
Returns:
A resolver id

setResolver

public void setResolver(java.lang.String resolverId)
Description copied from interface: IUIObject
Sets the resolver id for this object.

Specified by:
setResolver in interface IUIObject
Parameters:
resolverId - The resolver id.

addChild

public void addChild(IUIObject child)
              throws org.eclipse.core.runtime.CoreException
Description copied from interface: IUIObject
Adds a child to this object. Has no effects if child is already part of this object's children

Specified by:
addChild in interface IUIObject
Parameters:
child - The child to add
Throws:
org.eclipse.core.runtime.CoreException - In case of any unexpected error

childCount

public int childCount()
Description copied from interface: IUIObject
Returns the number of children that this UI object has

Specified by:
childCount in interface IUIObject
Returns:
the number of children of this object

getChildren

public IUIObject[] getChildren()
Description copied from interface: IUIObject
Returns the children of this UI object

Specified by:
getChildren in interface IUIObject
Returns:
The children of this UI object

removeChild

public IUIObject removeChild(IUIObject child)
Description copied from interface: IUIObject
Removes a child from this object

Specified by:
removeChild in interface IUIObject
Parameters:
child - The child to remove
Returns:
The child removed

getData

public java.lang.Object getData()
Description copied from interface: IUIObject
Returns the data associated with this object.

Specified by:
getData in interface IUIObject
Returns:
The associated data

setData

public void setData(java.lang.Object data)
Description copied from interface: IUIObject
Can be used to associate a general data object with this object.

Specified by:
setData in interface IUIObject
Parameters:
data - The data

findChild

public IUIObject findChild(java.lang.String referenceId)
Description copied from interface: IUIObject
Returns the child with a matching reference id passed in; null if none is found

Specified by:
findChild in interface IUIObject
Parameters:
referenceId - The reference id of the child
Returns:
A IUIObject with a matching referenceId or null if none is found.

TPTP 4.4.0 Testing Tools Project
Internal API Specification