|
IBM Rational Functional Tester Version 8.1.1000 IBM Rational Functional Tester API Reference Project Version 2.3 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IOperatingSystem
Enables access to some commonly used operating system commands that are not immediately available from the scripting language. Typically, the behavior of these commands depends upon the host operating system. The script developer must therefore adjust to the idiosyncrasies of the host operating system.
This interface is accessible through the
getOperatingSystem
method available directly to all scripts.
Method Summary | |
---|---|
java.lang.String |
getenv(java.lang.String name)
Gets the value of an environment variable. |
java.lang.String |
getEnvironment(java.lang.String variable)
Returns the value of a specified environment variable or null if the variable is not found in the current process's environment. |
int |
getForegroundLockTimeout()
Gets the foreground lock timeout (in milliseconds) on Windows. |
int |
getRegistryIntValue(java.lang.String key)
Gets an integer registry value. |
java.lang.String |
getRegistryValue(java.lang.String key)
Gets a String registry value. |
java.lang.String |
getVersion()
Returns a description of the operating system, including version information. |
boolean |
isWindows()
Returns true if the current operating system is Microsoft Windows. |
void |
setenv(java.lang.String name, java.lang.String value)
Sets the value of an environment variable. |
void |
setForegroundLockTimeout(int timeout)
Sets the foreground lock timeout (in milliseconds) on Windows. |
void |
unsetenv(java.lang.String name)
Sets an environment variable to null . |
Method Detail |
---|
java.lang.String getVersion()
String
is host dependent.
java.lang.String getEnvironment(java.lang.String variable)
null
if the variable is not found in the current process's environment.
boolean isWindows()
true
if the current operating system is Microsoft Windows.
int getForegroundLockTimeout() throws UnsupportedMethodException, NotSupportedOnUnixException
UnsupportedMethodException
NotSupportedOnUnixException
void setForegroundLockTimeout(int timeout) throws UnsupportedMethodException, NotSupportedOnUnixException
UnsupportedMethodException
NotSupportedOnUnixException
java.lang.String getRegistryValue(java.lang.String key) throws NotSupportedOnUnixException, NoSuchRegistryKeyException
String
registry value.
This is a native function. The input is the full registry path to the desired value, for example, "HKEY_CURRENT_MACHINE\SOFTWARE\Rational Software\Rational Test\8\Rational FT Install Directory".
The specified registry value is assumed to be a String
value, and its value is returned.
On Windows, the NoSuchRegistryKeyException
is thrown if the given key does not exist or is of the wrong type.
On UNIX, the implementation throws the NotSupportedOnUnixException
.
NotSupportedOnUnixException
NoSuchRegistryKeyException
int getRegistryIntValue(java.lang.String key) throws NotSupportedOnUnixException, NoSuchRegistryKeyException
integer
registry value. This is a native function.
The input is the full registry path to the desired value, for example, "HKEY_CURRENT_USER\Control Panel\Desktop\LowLevelHooksTimeout".
The specified registry value is assumed to be an integer (DWORD
) value.
Its value is returned.
On systems running Windows, the NoSuchRegistryKeyException
is thrown if the key does not exist or is of the wrong type.
On systems running Unix, the NotSupportedOnUnixException
is thrown.
NotSupportedOnUnixException
NoSuchRegistryKeyException
java.lang.String getenv(java.lang.String name)
void setenv(java.lang.String name, java.lang.String value)
void unsetenv(java.lang.String name)
null
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |