public class ComboBoxFunctions
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CAPTUREITEMSTOFILE_KEYWORD
"CaptureItemsToFile"
|
static java.lang.String |
CLICK_KEYWORD
"Click"
|
static java.lang.String |
HIDELIST_KEYWORD
"HideList"
|
static java.lang.String |
SELECT_KEYWORD
"Select"
|
static java.lang.String |
SELECTINDEX_KEYWORD
"SelectIndex"
|
static java.lang.String |
SELECTPARTIALMATCH_KEYWORD
"SelectPartialMatch"
|
static java.lang.String |
SELECTUNVERIFIED_KEYWORD
"SelectUnverified"
|
static java.lang.String |
SELECTUNVERIFIEDPARTIALMATCH_KEYWORD
"SelectUnverifiedPartialMatch"
|
static java.lang.String |
SETTEXTVALUE_KEYWORD
"SetTextValue"
|
static java.lang.String |
SETUNVERIFIEDTEXTVALUE_KEYWORD
"SetUnverifiedTextValue"
|
static java.lang.String |
SHOWLIST_KEYWORD
"ShowList"
|
static java.lang.String |
VERIFYSELECTED_KEYWORD
"VerifySelected"
|
Modifier and Type | Method and Description |
---|---|
static ComponentFunction |
captureItemsToFile(java.lang.String winname,
java.lang.String compname,
java.lang.String[] parameters)
Capture Items To a File specified (if not abs, then to test dir)
Capture Items To a File specified (if not abs, then to test dir)
|
static ComponentFunction |
captureItemsToFile(java.lang.String winname,
java.lang.String compname,
java.lang.String fileName,
java.lang.String fileEncoding)
Capture Items To a File specified (if not abs, then to test dir)
Capture Items To a File specified (if not abs, then to test dir)
|
static ComponentFunction |
click(java.lang.String winname,
java.lang.String compname)
Attempts to perform a standard Click on the ComboBox
Attempts to perform a standard Click on the ComboBox.
|
static ComboBoxFunctions |
getInstance()
public Singleton to access class static methods via instance
|
static ComponentFunction |
hideList(java.lang.String winname,
java.lang.String compname)
Hide the combo box list (equivalent to an ESC or two ESCs).
|
static ComponentFunction |
select(java.lang.String winname,
java.lang.String compname,
java.lang.String[] parameters)
Select an item by its text value from a combobox.
|
static ComponentFunction |
select(java.lang.String winname,
java.lang.String compname,
java.lang.String textValue,
java.lang.String forceRefresh)
Select an item by its text value from a combobox.
|
static ComponentFunction |
selectIndex(java.lang.String winname,
java.lang.String compname,
java.lang.String[] parameters)
Select an item by its index from a combobox.
|
static ComponentFunction |
selectIndex(java.lang.String winname,
java.lang.String compname,
java.lang.String indexValue,
java.lang.String forceRefresh)
Select an item by its index from a combobox.
|
static ComponentFunction |
selectPartialMatch(java.lang.String winname,
java.lang.String compname,
java.lang.String[] parameters)
Select an item via a partial text match in a combobox.
|
static ComponentFunction |
selectPartialMatch(java.lang.String winname,
java.lang.String compname,
java.lang.String textValue,
java.lang.String forceRefresh)
Select an item via a partial text match in a combobox.
|
static ComponentFunction |
selectUnverified(java.lang.String winname,
java.lang.String compname,
java.lang.String[] parameters)
Select an item by its text value from a combobox without verifying the
selection.
|
static ComponentFunction |
selectUnverified(java.lang.String winname,
java.lang.String compname,
java.lang.String textValue,
java.lang.String forceRefresh)
Select an item by its text value from a combobox without verifying the
selection.
|
static ComponentFunction |
selectUnverifiedPartialMatch(java.lang.String winname,
java.lang.String compname,
java.lang.String[] parameters)
Select an item via a partial text match in a combobox without verification.
|
static ComponentFunction |
selectUnverifiedPartialMatch(java.lang.String winname,
java.lang.String compname,
java.lang.String textValue,
java.lang.String forceRefresh)
Select an item via a partial text match in a combobox without verification.
|
static ComponentFunction |
setTextValue(java.lang.String winname,
java.lang.String compname,
java.lang.String textValue)
Set the text of the combobox
This action sets the text of the combobox.
|
static ComponentFunction |
setUnverifiedTextValue(java.lang.String winname,
java.lang.String compname,
java.lang.String textValue)
Set the text of the combobox without verification
This action sets the text of the combobox.
|
static ComponentFunction |
showList(java.lang.String winname,
java.lang.String compname)
Show the combo box list (expose it).
|
static ComponentFunction |
verifySelected(java.lang.String winname,
java.lang.String compname,
java.lang.String textValue)
Verify Selected item is equal to specified parameter
Verify Selected item is equal to specified parameter
|
public static final java.lang.String CAPTUREITEMSTOFILE_KEYWORD
public static final java.lang.String CLICK_KEYWORD
public static final java.lang.String HIDELIST_KEYWORD
public static final java.lang.String SELECT_KEYWORD
public static final java.lang.String SELECTINDEX_KEYWORD
public static final java.lang.String SELECTPARTIALMATCH_KEYWORD
public static final java.lang.String SELECTUNVERIFIED_KEYWORD
public static final java.lang.String SELECTUNVERIFIEDPARTIALMATCH_KEYWORD
public static final java.lang.String SETTEXTVALUE_KEYWORD
public static final java.lang.String SETUNVERIFIEDTEXTVALUE_KEYWORD
public static final java.lang.String SHOWLIST_KEYWORD
public static final java.lang.String VERIFYSELECTED_KEYWORD
public static ComboBoxFunctions getInstance()
public static ComponentFunction captureItemsToFile(java.lang.String winname, java.lang.String compname, java.lang.String fileName, java.lang.String fileEncoding)
Capture Items To a File specified (if not abs, then to test dir) Capture Items To a File specified (if not abs, then to test dir)Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.fileName
- Optional:NO
File name (if not absolute, then to test dir)fileEncoding
- Optional:YES DefaultVal:
Specify a character encoding to be used when saving data to a file.
If it is not specified, the system default file encoding will be used.
The encoding should be a valid string supported by Java; if it is
not valid, the system default file encoding will be used instead.public static ComponentFunction captureItemsToFile(java.lang.String winname, java.lang.String compname, java.lang.String[] parameters)
Capture Items To a File specified (if not abs, then to test dir) Capture Items To a File specified (if not abs, then to test dir)Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.parameters
- Optional:NO
An array containing the following parameters:
public static ComponentFunction click(java.lang.String winname, java.lang.String compname)
Attempts to perform a standard Click on the ComboBox Attempts to perform a standard Click on the ComboBox. If the combobox list is not exposed then this will expose the list of items. If the list is already exposed, then this will close the list. It must be noted that when you expose the list in a ComboBox, it is no longer a ComboBox. It typically converts to a ComboListBox. This may not be an issue on controls that Robot can recognize with a NAME=method. However, if the control is recognized by ObjectIndex or some other means then the original ComboBox may no longer be found on the screen. With this scenario, you need to reference the ComboBox and the ComboListBox in the application map (and associated data files) as two separate items. To avoid these potential problems, use the COMBOBOX 'SELECT' command to actually open the list and select the item all with a single command.Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.public static ComponentFunction hideList(java.lang.String winname, java.lang.String compname)
Hide the combo box list (equivalent to an ESC or two ESCs). hide the list. This would only be necessary in cases where the state of the combo box is not known ahead of time.Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.public static ComponentFunction select(java.lang.String winname, java.lang.String compname, java.lang.String textValue, java.lang.String forceRefresh)
Select an item by its text value from a combobox. Select an item by its text value from a combobox. This method combines the initial Click required to expose the list of items and then the subsequent selection of a text item from the list. The routine will first attempt to see if the item exists in the list and should provide a warning if it cannot find the item or cannot read the list of items. The routine will then attempt the selection. After the selection is attempted, the routine tries to verify that the list has the specified item as the selected item. A warning will be issued if the routine cannot read the list. A failure will be issued if the routine CAN read the list and determines that the specified item is NOT the currently selected item. Note: RobotJ also uses identical keyword SelectTextItemSupporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.textValue
- Optional:NO
The case-sensitive item in the drop down list to select.forceRefresh
- Optional:Yes
Force refreshing to update stale element after selection.public static ComponentFunction select(java.lang.String winname, java.lang.String compname, java.lang.String[] parameters)
Select an item by its text value from a combobox. Select an item by its text value from a combobox. This method combines the initial Click required to expose the list of items and then the subsequent selection of a text item from the list. The routine will first attempt to see if the item exists in the list and should provide a warning if it cannot find the item or cannot read the list of items. The routine will then attempt the selection. After the selection is attempted, the routine tries to verify that the list has the specified item as the selected item. A warning will be issued if the routine cannot read the list. A failure will be issued if the routine CAN read the list and determines that the specified item is NOT the currently selected item. Note: RobotJ also uses identical keyword SelectTextItemSupporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.parameters
- Optional:NO
An array containing the following parameters:
public static ComponentFunction selectIndex(java.lang.String winname, java.lang.String compname, java.lang.String indexValue, java.lang.String forceRefresh)
Select an item by its index from a combobox. Select an item by its index from a combobox. This method combines the initial Click required to expose the list of items and then the subsequent selection of the item from the list. The routine will first attempt to see if the index exists in the list and should provide a warning if it cannot find the item or cannot read the list of items. The routine will then attempt the selection.Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.indexValue
- Optional:NO
The item index in the drop down list to select.forceRefresh
- Optional:Yes
Force refreshing to update stale element after selection.public static ComponentFunction selectIndex(java.lang.String winname, java.lang.String compname, java.lang.String[] parameters)
Select an item by its index from a combobox. Select an item by its index from a combobox. This method combines the initial Click required to expose the list of items and then the subsequent selection of the item from the list. The routine will first attempt to see if the index exists in the list and should provide a warning if it cannot find the item or cannot read the list of items. The routine will then attempt the selection.Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.parameters
- Optional:NO
An array containing the following parameters:
public static ComponentFunction selectPartialMatch(java.lang.String winname, java.lang.String compname, java.lang.String textValue, java.lang.String forceRefresh)
Select an item via a partial text match in a combobox. Select an item via a partial text match in a combobox. This method combines the initial Click required to expose the list of items and then the subsequent selection of a text item from the list. The routine will first attempt to see if the item exists in the list and should provide a warning if it cannot find the item or cannot read the list of items. The routine will then attempt the selection. After the selection is attempted, the routine tries to verify that the list has the specified item as the selected item. A warning will be issued if the routine cannot read the list. A failure will be issued if the routine CAN read the list and determines that the specified item is NOT the currently selected item.Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.textValue
- Optional:NO
The case-sensitive substring of an item in the drop down list to select.forceRefresh
- Optional:Yes
Force refreshing to update stale element after selection.public static ComponentFunction selectPartialMatch(java.lang.String winname, java.lang.String compname, java.lang.String[] parameters)
Select an item via a partial text match in a combobox. Select an item via a partial text match in a combobox. This method combines the initial Click required to expose the list of items and then the subsequent selection of a text item from the list. The routine will first attempt to see if the item exists in the list and should provide a warning if it cannot find the item or cannot read the list of items. The routine will then attempt the selection. After the selection is attempted, the routine tries to verify that the list has the specified item as the selected item. A warning will be issued if the routine cannot read the list. A failure will be issued if the routine CAN read the list and determines that the specified item is NOT the currently selected item.Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.parameters
- Optional:NO
An array containing the following parameters:
public static ComponentFunction selectUnverified(java.lang.String winname, java.lang.String compname, java.lang.String textValue, java.lang.String forceRefresh)
Select an item by its text value from a combobox without verifying the selection. Select an item by its text value from a combobox without verifying the selection. This method combines the initial Click required to expose the list of items and then the subsequent selection of a text item from the list. The routine will simply take the specified text and attempt the selection. it will not verify the existence of the item before the attempt, nor will it verify the item is actually selected after the attempt. Note: RobotJ also uses identical keyword SelectUnverifiedTextItemSupporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.textValue
- Optional:NO
The case-sensitive item in the drop down list to select.forceRefresh
- Optional:Yes
Force refreshing to update stale element after selection.public static ComponentFunction selectUnverified(java.lang.String winname, java.lang.String compname, java.lang.String[] parameters)
Select an item by its text value from a combobox without verifying the selection. Select an item by its text value from a combobox without verifying the selection. This method combines the initial Click required to expose the list of items and then the subsequent selection of a text item from the list. The routine will simply take the specified text and attempt the selection. it will not verify the existence of the item before the attempt, nor will it verify the item is actually selected after the attempt. Note: RobotJ also uses identical keyword SelectUnverifiedTextItemSupporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.parameters
- Optional:NO
An array containing the following parameters:
public static ComponentFunction selectUnverifiedPartialMatch(java.lang.String winname, java.lang.String compname, java.lang.String textValue, java.lang.String forceRefresh)
Select an item via a partial text match in a combobox without verification. Select an item via a partial text match in a combobox without verification. This method combines the initial Click required to expose the list of items and then the subsequent selection of a text item from the list. The routine will first attempt to see if the item exists in the list and should provide a warning if it cannot find the item or cannot read the list of items. The routine will then attempt the selection. The routine will not verify the selected-item matches the parameter partial-text.Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.textValue
- Optional:NO
The case-sensitive substring of an item in the drop down list to select.forceRefresh
- Optional:Yes
Force refreshing to update stale element after selection.public static ComponentFunction selectUnverifiedPartialMatch(java.lang.String winname, java.lang.String compname, java.lang.String[] parameters)
Select an item via a partial text match in a combobox without verification. Select an item via a partial text match in a combobox without verification. This method combines the initial Click required to expose the list of items and then the subsequent selection of a text item from the list. The routine will first attempt to see if the item exists in the list and should provide a warning if it cannot find the item or cannot read the list of items. The routine will then attempt the selection. The routine will not verify the selected-item matches the parameter partial-text.Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.parameters
- Optional:NO
An array containing the following parameters:
public static ComponentFunction setTextValue(java.lang.String winname, java.lang.String compname, java.lang.String textValue)
Set the text of the combobox This action sets the text of the combobox. This version allows the use of special character combinations and substrings to identify specific keyboard keys. These are the same special characters and interpretation used for Robot's InputKeys command and the Windows Scripting Host. ~^+%{( are primarily the characters that induce special processing. The routine verifies we can read the text property, sets the text value and will verify that the property has been set to that value *IF* none of the special characters exist in the provided text value. If those special characters exist, then no post-set verification will occur.Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.textValue
- Optional:YES DefaultVal:
The text that will be typed into the ComboBox.public static ComponentFunction setUnverifiedTextValue(java.lang.String winname, java.lang.String compname, java.lang.String textValue)
Set the text of the combobox without verification This action sets the text of the combobox. This version allows the use of special character combinations and substrings to identify specific keyboard keys. These are the same special characters and interpretation used for Robot's InputKeys command and the Windows Scripting Host. ~^+%{( are primarily the characters that induce special processing. The routine verifies we can read the text property, sets the text value but does not verify that the property has been set to that value whether or not any of the special characters exist in the provided text value.Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.textValue
- Optional:YES DefaultVal:
The text that will be typed into the ComboBox.public static ComponentFunction showList(java.lang.String winname, java.lang.String compname)
Show the combo box list (expose it). show the list so that the next step can be a click on an item. This would only be necessary in cases where the state of the combo box is not known ahead of time.Supporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.public static ComponentFunction verifySelected(java.lang.String winname, java.lang.String compname, java.lang.String textValue)
Verify Selected item is equal to specified parameter Verify Selected item is equal to specified parameterSupporting Engines:
winname
- Optional:NO
The name of the window to act upon.compname
- Optional:NO
The name of the component to act upon.textValue
- Optional:NO
The case-sensitive substring to compare.Copyright © SAS Institute. All Rights Reserved.