OpenText™ Functional Testing for Developers JavaScript SDK

UIAPro. MenuItem

The description of a UIAPro menu item test object.
Parameters:
Name Type Attributes Description
props Object <optional>
Initializes a UIAPro Menu Item test object using the supplied property bag.
Returns:
the description object that was initialized.
Type
MenuItem

Methods

absX(absXopt) → {number|Description}

The object's absolute x-coordinate (left) relative to the parent object (in pixels).
Parameters:
Name Type Attributes Description
absX number <optional>
When provided, this method acts as a setter and sets the absX value.
Returns:
The current stored absX value; otherwise it returns 'this' for use with the builder pattern.
Type
number | Description

absY(absYopt) → {number|Description}

The object's absolute y-coordinate (top) relative to the parent object (in pixels).
Parameters:
Name Type Attributes Description
absY number <optional>
When provided, this method acts as a setter and sets the absY value.
Returns:
The current stored absY value; otherwise it returns 'this' for use with the builder pattern.
Type
number | Description

acceleratorKey(acceleratorKeyopt) → {string|Description}

The sequence of key combinations that invoke an action associated with the element.
Parameters:
Name Type Attributes Description
acceleratorKey string <optional>
When provided, this method acts as a setter and sets the acceleratorKey value.
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored acceleratorKey value; otherwise it returns 'this' for use with the builder pattern.
Type
string | Description

accessKey(accessKeyopt) → {string|Description}

The character that is used to activate the object.
Parameters:
Name Type Attributes Description
accessKey string <optional>
When provided, this method acts as a setter and sets the accessKey value.
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored accessKey value; otherwise it returns 'this' for use with the builder pattern.
Type
string | Description

automationId(automationIdopt) → {string|Description}

The ID for an object that is unique among siblings within its container.
Parameters:
Name Type Attributes Description
automationId string <optional>
When provided, this method acts as a setter and sets the automationId value.
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored automationId value; otherwise it returns 'this' for use with the builder pattern.
Type
string | Description

controlType(controlTypeopt) → {string|Description}

The UIAPro type for the object.
Parameters:
Name Type Attributes Description
controlType string <optional>
When provided, this method acts as a setter and sets the controlType value.
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored controlType value; otherwise it returns 'this' for use with the builder pattern.
Type
string | Description

frameworkId(frameworkIdopt) → {string|Description}

The name of the UI framework, such as Win32, WinForm, or DirectUI.
Parameters:
Name Type Attributes Description
frameworkId string <optional>
When provided, this method acts as a setter and sets the frameworkId value.
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored frameworkId value; otherwise it returns 'this' for use with the builder pattern.
Type
string | Description

handle(handleopt) → {number|Description}

The run-time object's window handle.
Parameters:
Name Type Attributes Description
handle number <optional>
When provided, this method acts as a setter and sets the handle value.
Returns:
The current stored handle value; otherwise it returns 'this' for use with the builder pattern.
Type
number | Description

hasKeyBoardFocus(hasKeyBoardFocusopt) → {boolean|Description}

Indicates whether the object has keyboard focus.
Parameters:
Name Type Attributes Description
hasKeyBoardFocus boolean <optional>
When provided, this method acts as a setter and sets the hasKeyBoardFocus value.
Returns:
The current stored hasKeyBoardFocus value; otherwise it returns 'this' for use with the builder pattern.
Type
boolean | Description

height(heightopt) → {number|Description}

The object's height (in pixels).
Parameters:
Name Type Attributes Description
height number <optional>
When provided, this method acts as a setter and sets the height value.
Returns:
The current stored height value; otherwise it returns 'this' for use with the builder pattern.
Type
number | Description

isEnabled(isEnabledopt) → {boolean|Description}

Indicates whether the object is enabled.
Parameters:
Name Type Attributes Description
isEnabled boolean <optional>
When provided, this method acts as a setter and sets the isEnabled value.
Returns:
The current stored isEnabled value; otherwise it returns 'this' for use with the builder pattern.
Type
boolean | Description

isKeyboardFocusable(isKeyboardFocusableopt) → {boolean|Description}

Indicates whether the object can accept keyboard focus.
Parameters:
Name Type Attributes Description
isKeyboardFocusable boolean <optional>
When provided, this method acts as a setter and sets the isKeyboardFocusable value.
Returns:
The current stored isKeyboardFocusable value; otherwise it returns 'this' for use with the builder pattern.
Type
boolean | Description

isOffScreen(isOffScreenopt) → {boolean|Description}

Indicates whether the object is Offscreen.
Parameters:
Name Type Attributes Description
isOffScreen boolean <optional>
When provided, this method acts as a setter and sets the isOffScreen value.
Returns:
The current stored isOffScreen value; otherwise it returns 'this' for use with the builder pattern.
Type
boolean | Description

isPassword(isPasswordopt) → {boolean|Description}

Indicates whether the object contains protected content or a password.
Parameters:
Name Type Attributes Description
isPassword boolean <optional>
When provided, this method acts as a setter and sets the isPassword value.
Returns:
The current stored isPassword value; otherwise it returns 'this' for use with the builder pattern.
Type
boolean | Description

name(nameopt) → {string|Description}

The name of the control.
Parameters:
Name Type Attributes Description
name string <optional>
When provided, this method acts as a setter and sets the name value.
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored name value; otherwise it returns 'this' for use with the builder pattern.
Type
string | Description

nativeClass(nativeClassopt) → {string|Description}

The class name assigned to the test object.
Parameters:
Name Type Attributes Description
nativeClass string <optional>
When provided, this method acts as a setter and sets the nativeClass value.
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored nativeClass value; otherwise it returns 'this' for use with the builder pattern.
Type
string | Description

path(pathopt) → {string|Description}

The path in the application's object hierarchy, separated by semicolons. Objects in the path are represented by their name or automationId property values.
Parameters:
Name Type Attributes Description
path string <optional>
When provided, this method acts as a setter and sets the path value.
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored path value; otherwise it returns 'this' for use with the builder pattern.
Type
string | Description

processId(processIdopt) → {number|Description}

The UIAutomation object process id.
Parameters:
Name Type Attributes Description
processId number <optional>
When provided, this method acts as a setter and sets the processId value.
Returns:
The current stored processId value; otherwise it returns 'this' for use with the builder pattern.
Type
number | Description

processName(processNameopt) → {string|Description}

The UIAutomation object process name.
Parameters:
Name Type Attributes Description
processName string <optional>
When provided, this method acts as a setter and sets the processName value.
Returns:
The current stored processName value; otherwise it returns 'this' for use with the builder pattern.
Type
string | Description

status(statusopt) → {string|Description}

Describes the status of the current object. For example, an item associated with a contact in a messaging application might be "Busy" or "Connected".
Parameters:
Name Type Attributes Description
status string <optional>
When provided, this method acts as a setter and sets the status value.
Returns:
The current stored status value; otherwise it returns 'this' for use with the builder pattern.
Type
string | Description

supportedPatterns(supportedPatternsopt) → {Array.<string>|Description}

The list of patterns supported for the test object.
Parameters:
Name Type Attributes Description
supportedPatterns Array.<string> <optional>
When provided, this method acts as a setter and sets the supportedPatterns value.
Returns:
If no parameter is provided, the method acts as a getter and returns the current stored supportedPatterns value; otherwise it returns 'this' for use with the builder pattern.
Type
Array.<string> | Description

width(widthopt) → {number|Description}

The object's width (in pixels).
Parameters:
Name Type Attributes Description
width number <optional>
When provided, this method acts as a setter and sets the width value.
Returns:
The current stored width value; otherwise it returns 'this' for use with the builder pattern.
Type
number | Description

x(xopt) → {number|Description}

The object's x-coordinate (left) relative to the parent object (in pixels).
Parameters:
Name Type Attributes Description
x number <optional>
When provided, this method acts as a setter and sets the x value.
Returns:
The current stored x value; otherwise it returns 'this' for use with the builder pattern.
Type
number | Description

y(yopt) → {number|Description}

The object's y-coordinate (top) relative to the parent object (in pixels).
Parameters:
Name Type Attributes Description
y number <optional>
When provided, this method acts as a setter and sets the y value.
Returns:
The current stored y value; otherwise it returns 'this' for use with the builder pattern.
Type
number | Description