Share this page
AiObject
new AiObject(propsopt) → {AiObject}
The description of an object identified using Artificial Intelligence.
Parameters:
Name | Type | Attributes | Description |
---|
props | Object |
<optional>
| Initializes a description of an object identified using Artificial Intelligence.
using the supplied property bag. |
Returns:
the description object that was initialized.
-
Type
- AiObject
Methods
aiClass(aiClassopt) → {string|Description}
the AI Class type of the AI object list of supported classes can be taken from
AI.AiTypes.
Parameters:
Name | Type | Attributes | Description |
---|
aiClass | string |
<optional>
| When provided, this method acts as a setter and sets the aiClass value. |
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored aiClass value;
otherwise it returns 'this' for use with the builder pattern.
-
Type
- string
|
Description
locator(locatoropt) → {object|Description}
Used to describe the unique location of an object that may appear multiple times in the application.
Parameters:
Name | Type | Attributes | Description |
---|
locator | object |
<optional>
| When provided, this method acts as a setter and sets the locator value. Properties UFT Developer 2022 and later:
Should be either AI.PositionalLocator or AI.RelationalLocator. UFT Developer 2021 R1 and earlier: Name | Type | Attributes | Description |
---|
direction | string |
<optional>
| The direction of the AI object, can be either: fromLeft, fromRight, fromTop or fromBottom. | index | number |
<optional>
| The 0-based index from the given direction of the AI object. |
|
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored locator value;
otherwise it returns 'this' for use with the builder pattern.
-
Type
- object
|
Description
text(textopt) → {string|Description}
The object's attached text.
Parameters:
Name | Type | Attributes | Description |
---|
text | string |
<optional>
| When provided, this method acts as a setter and sets the text value. |
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored text value;
otherwise it returns 'this' for use with the builder pattern.
-
Type
- string
|
Description
Tips to improve your search results...
UFT Developer JavaScript SDK ReferenceVersion: 2021-2023UFT Developer SDK ReferenceAllView Local Help CenterView Online Help CenterbackGo back in browser historyforwardGo forward in browser historyRemove search highlightsnext topicGo to next topicprevious topicGo to previous topicPrint the current topicVersion: