public abstract static class DriverConstant.SeleniumConfigConstant extends Constants.SeleniumConstants
DriverConstant.SECTION_SAFS_SELENIUM
for SELENIUM.Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_BROWSER_TIMEOUT
0 seconds, means that the browser is allowed to hang forever.
|
static boolean |
DEFAULT_BYPASS_FRAME_RESET
false Do not bypass the frame reset, by default, search algorithms begin every search by switching back to the topmost root HTML document (frame).
|
static boolean |
DEFAULT_BYPASS_ROBOT_ACTION
false Do not bypass the robot.action, by default our library will handle click actions by Robot firstly, if failed then handle it by selenium.
|
static int |
DEFAULT_CONNECTION_TEST_MAX_DURATION
5000 defines the default maximum duration (in milliseconds) that user can accept when executing
selenium-driver-command
defined by
PROPERTY_CONNECTION_TEST_COMMAND or ITEM_CONNECTION_TEST_COMMAND . |
static int |
DEFAULT_CONNECTION_TEST_MAX_TRY
2 defines the maximum times to try to get a good connection.
|
static int |
DEFAULT_DELAY_GET_CONTENT
0 milliseconds delay waiting for the refresh of a webelement before getting its content.
|
static java.lang.String |
DEFAULT_JVM_MEMORY_MAXIMUM
"2g" default maximum memory for the SELENIUM server
|
static java.lang.String |
DEFAULT_JVM_MEMORY_MINIMUM
"512m" default minimum memory for the SELENIUM server
|
static int |
DEFAULT_REGISTRY_PORT
the default port
1099 used by the registry for looking up the RMI server |
static boolean |
DEFAULT_RMI_PORT_FORWARD
false Do not use 'rmi port forward', our library will connect the RMI server running on docker container by container's IP and port.
|
static java.lang.String |
DEFAULT_SELENIUM_HOST
'localhost' the default host where the SELENIUM server will run
|
static java.lang.String |
DEFAULT_SELENIUM_HOST_IP
'127.0.0.1' the default host where the SELENIUM server will run
|
static java.lang.String |
DEFAULT_SELENIUM_NODE_PORT
'5555' the default port number on which the SELENIUM node will run
|
static int |
DEFAULT_SELENIUM_NODE_PORT_INT
5555
|
static java.lang.String |
DEFAULT_SELENIUM_PORT
'4444' the default port number on which the SELENIUM "standalone server"/"grid hub" will run
|
static int |
DEFAULT_SELENIUM_PORT_INT
4444
|
static int |
DEFAULT_TIMEOUT
0 seconds, means that the client is NEVER allowed to be gone before the session is reclaimed
|
static boolean |
DEFAULT_WAIT_READY
false means that we don't wait the component's ready before trying to handle it.
|
static java.lang.String |
ITEM_BROWSER_TIMEOUT
"browser.timeout" defines the timeout in seconds a node is willing to hang inside the browser.
The timeout value is an integer. It is an item under section DriverConstant.SECTION_SAFS_SELENIUM Examples: [SAFS_SELENIUM] browser.timeout=200 The node is willing to hang 200 seconds. |
static java.lang.String |
ITEM_BYPASS_FRAME_RESET
"bypass.frame.reset" By default, search algorithms begin every search by switching back to the topmost root HTML document (frame).
Set bypass.frame.reset to true if you wish to disable this frames reset at the beginning of every component search. It is an item under section DriverConstant.SECTION_SAFS_SELENIUM Examples: [SAFS_SELENIUM] bypass.frame.reset=true | false NOTE: If this is set to true, user MUST handle the frame-switch by himself and should NOT define any "frame information" in the Recognition String in MAP file. |
static java.lang.String |
ITEM_BYPASS_ROBOT_ACTION
"bypass.robot.action" By default, our library will handle click actions by Robot firstly, if failed then handle it by selenium.
Set bypass.robot.action to true if you wish to skip the Robot. It is an item under section DriverConstant.SECTION_SAFS_SELENIUM Examples: [SAFS_SELENIUM] bypass.robot.action=true | false |
static java.lang.String |
ITEM_CONNECTION_TEST_COMMAND
"connection.test.command" defines the selenium-driver-command
used to test the connection between WebDriver and BrowserDriver.
selenium-driver-command is a string understood by a remote server using the JSON wire protocol. It is an item under section DriverConstant.SECTION_SAFS_SELENIUM Examples: [SAFS_SELENIUM] connection.test.command=getAlertText connection.test.command=getCurrentWindowSize |
static java.lang.String |
ITEM_CONNECTION_TEST_MAX_DURATION
"connection.test.max.duration" defines the maximum duration (in milliseconds) that user can accept when executing
selenium-driver-command
defined by
PROPERTY_CONNECTION_TEST_COMMAND or ITEM_CONNECTION_TEST_COMMAND .It is an item under section DriverConstant.SECTION_SAFS_SELENIUM Examples: [SAFS_SELENIUM] connection.test.max.duration=3000 |
static java.lang.String |
ITEM_CONNECTION_TEST_MAX_TRY
"connection.test.max.try" defines the maximum times to try to get a good connection between WebDriver and BrowserDriver
It is an item under section DriverConstant.SECTION_SAFS_SELENIUM Examples: [SAFS_SELENIUM] connection.test.max.try=10 |
static java.lang.String |
ITEM_CONSOLE_STATE
"CONSOLE_STATE" defines the state of the JVM console for the SELENIUM server
The value can be: MAX|MIN|NORMAL|MAXIMIZE|MINIMIZE Examples: [SAFS_SELENIUM] CONSOLE_STATE=MAX Selenium Server console will be maximized. |
static java.lang.String |
ITEM_DELAY_WAIT_REFRESH
"delay.get.content" defines the delay (milliseconds) waiting for the refresh of a webelement before getting its content.
|
static java.lang.String |
ITEM_REGISTRY_PORT
"registry.port" By default, our library will use
1099 as the port to get the registry for looking up the RMI server.Set registry.port to another port if the registry is created with different port. It is an item under section DriverConstant.SECTION_SAFS_SELENIUM Examples: [SAFS_SELENIUM] registry.port=1100 |
static java.lang.String |
ITEM_RMI_PORT_FORWARD
"rmi.port.forward" With docker, by default, our library will connect the RMI server running on docker container by container's IP and port.
But we can map the container's port to local-machine's port so that our library will connect the RMI server (running on docker container) by "localhost" and the mapped port. Set rmi.port.forward to true if you want our library to connect the RMI server (running on docker container) by "localhost" and the mapped port. It is an item under section DriverConstant.SECTION_SAFS_SELENIUM Examples: [SAFS_SELENIUM] rmi.port.forward=true | false |
static java.lang.String |
ITEM_SERVER_LAUNCH_SCRIPT
"server.launch.script" is the absolute path of the script for launching the selenium server.
|
static java.lang.String |
ITEM_TIMEOUT
"timeout" defines the timeout in seconds before the hub automatically releases a node that hasn't received any requests for more than the specified number of seconds.
The timeout value is an integer. It is an item under section DriverConstant.SECTION_SAFS_SELENIUM Examples: [SAFS_SELENIUM] timeout=200 The node can stay idle for 200 seconds before being released by the hub. |
static java.lang.String |
ITEM_WAIT_READY
"wait.ready" defines if the component will not be handled until it is ready.
It is a boolean value, the default value is false. It is an item under section DriverConstant.SECTION_SAFS_SELENIUM Examples: [SAFS_SELENIUM] wait.ready=true The component will not be handled until it is ready. |
static java.lang.String |
ITEM_WEB_DRIVERS
"WEB_DRIVERS" defines a set of drivers to start with the selenium-server.
The value can be a combination (separated by a colon :) of BrowserConstants#BROWSER_NAME_IE
BrowserConstants#BROWSER_NAME_CHROME
BrowserConstants#BROWSER_NAME_EDGE
BrowserConstants.BROWSER_NAME_XXX might be supported. |
static java.lang.String |
PROPERTY_BROWSER_TIMEOUT
"safs.selenium.browser.timeout" defines the timeout in seconds a selenium node is willing to hang inside the browser.
The timeout value is an integer. Examples: -Dsafs.selenium.browser.timeout=200 The node is willing to hang 200 seconds. |
static java.lang.String |
PROPERTY_BYPASS_FRAME_RESET
"safs.selenium.bypass.frame.reset" By default, search algorithms begin every search by switching back to the topmost root HTML document (frame).
Set safs.selenium.bypass.frame.reset to true if you wish to disable this frames reset at the beginning of every component search. Examples: -Dsafs.selenium.bypass.frame.reset=true | false NOTE: If this is set to true, user MUST handle the frame-switch by himself and should NOT define any "frame information" in the Recognition String in MAP file. |
static java.lang.String |
PROPERTY_BYPASS_ROBOT_ACTION
"safs.selenium.bypass.robot.action" By default, our library will handle click actions by Robot firstly, if failed then handle it by selenium.
Set safs.selenium.bypass.robot.action to true if you wish to skip the Robot. Examples: -Dsafs.selenium.bypass.robot.action=true | false |
static java.lang.String |
PROPERTY_CONNECTION_TEST_COMMAND
"safs.selenium.connection.test.command" defines the selenium-driver-command
used to test the connection between WebDriver and BrowserDriver.
selenium-driver-command is a string understood by a remote server using the JSON wire protocol. Examples: -Dsafs.selenium.connection.test.command=getAlertText -Dsafs.selenium.connection.test.command=getCurrentWindowSize |
static java.lang.String |
PROPERTY_CONNECTION_TEST_MAX_DURATION
"safs.selenium.connection.test.max.duration" defines the maximum duration (in milliseconds) that user can accept when executing
selenium-driver-command
defined by
PROPERTY_CONNECTION_TEST_COMMAND or ITEM_CONNECTION_TEST_COMMAND .Examples: -Dsafs.selenium.connection.test.max.duration=3000 |
static java.lang.String |
PROPERTY_CONNECTION_TEST_MAX_TRY
"safs.selenium.connection.test.max.try" defines the maximum times to try to get a good connection between WebDriver and BrowserDriver
Examples: -Dsafs.selenium.connection.test.max.try=10 |
static java.lang.String |
PROPERTY_CONSOLE_STATE
"safs.selenium.console.state" defines the state of the JVM console for the SELENIUM server
JVM command line: -Dsafs.selenium.console.state=MAX|MIN|NORMAL|MAXIMIZE|MINIMIZE Examples: -Dsafs.selenium.console.state=MAX Selenium Server console will be maximized. |
static java.lang.String |
PROPERTY_DELAY_GET_CONTENT
"safs.selenium.delay.get.content" defines the delay (milliseconds) waiting for the refresh of a webelement before getting its content.
|
static java.lang.String |
PROPERTY_REGISTRY_PORT
"safs.selenium.registry.port" By default, our library will use
1099 as the port to get the registry for looking up the RMI server.Set safs.selenium.registry.port to another port if the registry is created with different port. Examples: -Dsafs.selenium.registry.port=1100 |
static java.lang.String |
PROPERTY_RMI_PORT_FORWARD
"safs.selenium.rmi.port.forward" With docker, by default, our library will connect the RMI server running on docker container by container's IP and port.
But we can map the container's port to local-machine's port so that our library will connect the RMI server (running on docker container) by "localhost" and the mapped port. Set safs.selenium.rmi.port.forward to true if you want our library to connect the RMI server (running on docker container) by "localhost" and the mapped port. Examples: -Dsafs.selenium.rmi.port.forward=true | false |
static java.lang.String |
PROPERTY_SELENIUMSERVER_JVM
"safs.selenium.server.jvm" defines the JVM to start the SELENIUM server.
The value should be an absolute path of the java.exe executable, for example as following -Dsafs.selenium.server.jvm="D:\jdk\jdk1.7.0_45_64bit\bin\java.exe" |
static java.lang.String |
PROPERTY_SELENIUMSERVER_JVM_OPTIONS
"safs.selenium.server.jvm.options" defines the JVM Options for the SELENIUM server.
|
static java.lang.String |
PROPERTY_SELENIUMSERVER_JVM_Xms
"safs.selenium.server.jvm.xms" define the minimum memory to use for the SELENIUM server
Examples:
-Dsafs.selenium.server.jvm.xms=512m |
static java.lang.String |
PROPERTY_SELENIUMSERVER_JVM_Xmx
"safs.selenium.server.jvm.xmx" define the maximum memory to use for the SELENIUM server
To use a very high memory, 4g for example, you may need to specify the PROPERTY_SELENIUMSERVER_JVM to use 64 bits Java.Examples: -Dsafs.selenium.server.jvm.xmx=2g |
static java.lang.String |
PROPERTY_SERVER_LAUNCH_SCRIPT
"safs.selenium.server.launch.script" is the absolute path of the script for launching the selenium server.
If this item is specified, many other properties, such as 'selenium.host', 'selenium.port' and 'selenium.node' etc., should also be specified consistently. |
static java.lang.String |
PROPERTY_TIMEOUT
"safs.selenium.timeout" defines the timeout in seconds before the selenium hub automatically releases a node that hasn't received any requests for more than the specified number of seconds.
The timeout value is an integer. Examples: -Dsafs.selenium.timeout=200 The node can stay idle for 200 seconds before being released by the hub. |
static java.lang.String |
PROPERTY_WAIT_READY
"safs.selenium.wait.ready" defines if the component will not be handled until it is ready.
It is a boolean value, the default value is false. Examples: -Dsafs.selenium.wait.ready=true The component will not be handled until it is ready. |
static java.lang.String |
PROPERTY_WEB_DRIVERS
"safs.selenium.web.drivers" defines a set of drivers to start with the selenium-server.
The value can be a combination (separated by a colon :) of BrowserConstants#BROWSER_NAME_IE
BrowserConstants#BROWSER_NAME_CHROME
BrowserConstants#BROWSER_NAME_EDGE
BrowserConstants.BROWSER_NAME_XXX might be supported. |
static java.lang.String |
SELENIUMHOST
"SELENIUMHOST" define the host name where the SELENIUM "standalone server"/"grid hub" will run
|
static java.lang.String |
SELENIUMNODE
"SELENIUMNODE" define the selenium nodes to run.
|
static java.lang.String |
SELENIUMPORT
"SELENIUMPORT" define the port number on which the SELENIUM "standalone server"/"grid hub" will run
|
static java.lang.String |
SELENIUMSERVER_JVM
"SELENIUMSERVER_JVM" defines the JVM to start the SELENIUM server.
The value should be an absolute path of the java.exe executable Examples: [SAFS_SELENIUM] SELENIUMSERVER_JVM="D:\jdk\jdk1.7.0_45_64bit\bin\java.exe" |
static java.lang.String |
SELENIUMSERVER_JVM_OPTIONS
"SELENIUMSERVER_JVM_OPTIONS" defines the JVM Options for the SELENIUM server.
|
static java.lang.String |
SELENIUMSERVER_JVM_Xms
"SELENIUMSERVER_JVM_Xms" define the minimum memory to use for the SELENIUM server
Examples:
[SAFS_SELENIUM] SELENIUMSERVER_JVM_Xmx=512m |
static java.lang.String |
SELENIUMSERVER_JVM_Xmx
"SELENIUMSERVER_JVM_Xmx" define the maximum memory to use for the SELENIUM server
To use a very high memory, 4g for example, you may need to specify the SELENIUMSERVER_JVM to use 64 bits Java.Examples: [SAFS_SELENIUM] SELENIUMSERVER_JVM_Xmx=2g |
DEFAULT_SUPPORTED_BROWSERS, DRIVER_SHORT_NAME_MAP, KEY_GRID_NODES_SETTING, SYSTEM_PROPERTY_BROWSER_NAME, SYSTEM_PROPERTY_BROWSER_REMOTE, SYSTEM_PROPERTY_SELENIUM_HOST, SYSTEM_PROPERTY_SELENIUM_NODE, SYSTEM_PROPERTY_SELENIUM_PORT, SYSTEM_PROPERTY_WEBDRIVER_CHROME, SYSTEM_PROPERTY_WEBDRIVER_EDGE, SYSTEM_PROPERTY_WEBDRIVER_IE
Constructor and Description |
---|
SeleniumConfigConstant() |
getDefaultSupportedBrowsers
public static final java.lang.String ITEM_SERVER_LAUNCH_SCRIPT
DriverConstant.SECTION_SAFS_SELENIUM
SELENIUMHOST
, SELENIUMPORT
and SELENIUMNODE
etc. should also be specified consistently.public static final java.lang.String PROPERTY_SERVER_LAUNCH_SCRIPT
public static final java.lang.String SELENIUMHOST
SELENIUMPORT
,
Constant Field Valuespublic static final java.lang.String DEFAULT_SELENIUM_HOST
public static final java.lang.String DEFAULT_SELENIUM_HOST_IP
public static final java.lang.String SELENIUMPORT
SELENIUMHOST
,
Constant Field Valuespublic static final int DEFAULT_SELENIUM_PORT_INT
public static final java.lang.String DEFAULT_SELENIUM_PORT
public static final int DEFAULT_SELENIUM_NODE_PORT_INT
public static final java.lang.String DEFAULT_SELENIUM_NODE_PORT
public static final java.lang.String SELENIUMNODE
SELENIUMHOST
will be considered as "standalone server"
If this is provided, then SELENIUMHOST
will be considered as "grid hub" on which all nodes will register.SELENIUMHOST
,
Constant Field Valuespublic static final java.lang.String SELENIUMSERVER_JVM_Xmx
SELENIUMSERVER_JVM
to use 64 bits Java.SELENIUMSERVER_JVM_Xms
,
Constant Field Valuespublic static final java.lang.String PROPERTY_SELENIUMSERVER_JVM_Xmx
PROPERTY_SELENIUMSERVER_JVM
to use 64 bits Java.public static java.lang.String DEFAULT_JVM_MEMORY_MAXIMUM
public static final java.lang.String SELENIUMSERVER_JVM_Xms
SELENIUMSERVER_JVM_Xmx
,
Constant Field Valuespublic static final java.lang.String PROPERTY_SELENIUMSERVER_JVM_Xms
public static java.lang.String DEFAULT_JVM_MEMORY_MINIMUM
public static final java.lang.String SELENIUMSERVER_JVM_OPTIONS
SELENIUMSERVER_JVM_Xms
and SELENIUMSERVER_JVM_Xmx
are finer, if they exist then
they will be used instead of the options specified in SELENIUMSERVER_JVM_OPTIONS
.SELENIUMSERVER_JVM
to use 64 bits Java.public static final java.lang.String PROPERTY_SELENIUMSERVER_JVM_OPTIONS
PROPERTY_SELENIUMSERVER_JVM_Xms
and PROPERTY_SELENIUMSERVER_JVM_Xmx
are finer, if they exist then
they will be used instead of the options specified in PROPERTY_SELENIUMSERVER_JVM_OPTIONS
.PROPERTY_SELENIUMSERVER_JVM
to use 64 bits Java.public static final java.lang.String SELENIUMSERVER_JVM
public static final java.lang.String PROPERTY_SELENIUMSERVER_JVM
public static final java.lang.String ITEM_CONSOLE_STATE
public static final java.lang.String PROPERTY_CONSOLE_STATE
public static final java.lang.String ITEM_WEB_DRIVERS
BrowserConstants#BROWSER_NAME_IE
BrowserConstants#BROWSER_NAME_CHROME
BrowserConstants#BROWSER_NAME_EDGE
DriverConstant.SECTION_SAFS_SELENIUM
public static final java.lang.String PROPERTY_WEB_DRIVERS
BrowserConstants#BROWSER_NAME_IE
BrowserConstants#BROWSER_NAME_CHROME
BrowserConstants#BROWSER_NAME_EDGE
public static final int DEFAULT_TIMEOUT
ITEM_TIMEOUT
,
PROPERTY_TIMEOUT
,
Constant Field Valuespublic static final int DEFAULT_BROWSER_TIMEOUT
public static final java.lang.String ITEM_TIMEOUT
DriverConstant.SECTION_SAFS_SELENIUM
public static final java.lang.String PROPERTY_TIMEOUT
public static final boolean DEFAULT_WAIT_READY
ITEM_WAIT_READY
,
PROPERTY_WAIT_READY
,
Constant Field Valuespublic static final java.lang.String ITEM_WAIT_READY
DriverConstant.SECTION_SAFS_SELENIUM
public static final java.lang.String PROPERTY_WAIT_READY
public static final java.lang.String ITEM_BROWSER_TIMEOUT
DriverConstant.SECTION_SAFS_SELENIUM
public static final java.lang.String PROPERTY_BROWSER_TIMEOUT
public static final java.lang.String ITEM_CONNECTION_TEST_COMMAND
DriverConstant.SECTION_SAFS_SELENIUM
public static final java.lang.String PROPERTY_CONNECTION_TEST_COMMAND
public static final java.lang.String ITEM_CONNECTION_TEST_MAX_DURATION
PROPERTY_CONNECTION_TEST_COMMAND
or ITEM_CONNECTION_TEST_COMMAND
.DriverConstant.SECTION_SAFS_SELENIUM
public static final java.lang.String PROPERTY_CONNECTION_TEST_MAX_DURATION
PROPERTY_CONNECTION_TEST_COMMAND
or ITEM_CONNECTION_TEST_COMMAND
.public static final int DEFAULT_CONNECTION_TEST_MAX_DURATION
PROPERTY_CONNECTION_TEST_COMMAND
or ITEM_CONNECTION_TEST_COMMAND
.public static final java.lang.String ITEM_CONNECTION_TEST_MAX_TRY
DriverConstant.SECTION_SAFS_SELENIUM
public static final java.lang.String PROPERTY_CONNECTION_TEST_MAX_TRY
public static final int DEFAULT_CONNECTION_TEST_MAX_TRY
public static final java.lang.String ITEM_DELAY_WAIT_REFRESH
DriverConstant.SECTION_SAFS_SELENIUM
public static final java.lang.String PROPERTY_DELAY_GET_CONTENT
Sometimes the Component's content will get refreshed (the html tag will be redrawn on page), we need to wait before it is ready. Otherwise, the content is stale and StaleElementReferenceException will be thrown out if we try to operate the content.
public static final int DEFAULT_DELAY_GET_CONTENT
public static final java.lang.String ITEM_BYPASS_FRAME_RESET
DriverConstant.SECTION_SAFS_SELENIUM
WebDriver().switchTo().defaultContent(); WebDriver().switchTo().frame("my_iframe"); //SeleniumPlus will search components on frame "my_iframe".
public static final java.lang.String PROPERTY_BYPASS_FRAME_RESET
WebDriver().switchTo().defaultContent(); WebDriver().switchTo().frame("my_iframe"); //SeleniumPlus will search components on frame "my_iframe".
public static final boolean DEFAULT_BYPASS_FRAME_RESET
public static final java.lang.String ITEM_BYPASS_ROBOT_ACTION
DriverConstant.SECTION_SAFS_SELENIUM
public static final java.lang.String PROPERTY_BYPASS_ROBOT_ACTION
public static final boolean DEFAULT_BYPASS_ROBOT_ACTION
public static final java.lang.String ITEM_RMI_PORT_FORWARD
DriverConstant.SECTION_SAFS_SELENIUM
public static final java.lang.String PROPERTY_RMI_PORT_FORWARD
public static final boolean DEFAULT_RMI_PORT_FORWARD
public static final java.lang.String ITEM_REGISTRY_PORT
1099
as the port to get the registry for looking up the RMI server.DriverConstant.SECTION_SAFS_SELENIUM
public static final java.lang.String PROPERTY_REGISTRY_PORT
1099
as the port to get the registry for looking up the RMI server.public static final int DEFAULT_REGISTRY_PORT
1099
used by the registry for looking up the RMI serverCopyright © SAS Institute. All Rights Reserved.