Package org.openqa.selenium.os
Class CommandLine
java.lang.Object
org.openqa.selenium.os.CommandLine
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidcopyOutputTo(OutputStream out) intdestroy()Destroy the current command.voidexecute()voidintstatic StringbooleanCheck whether the current command is still executing.booleanvoidsetDynamicLibraryPath(String newLibraryPath) voidsetEnvironmentVariable(String name, String value) Adds the specified environment variable.voidsetEnvironmentVariables(Map<String, String> environment) Adds the specified environment variables.voidvoidsetWorkingDirectory(String workingDirectory) toString()voidupdateDynamicLibraryPath(String extraPath) voidwaitFor()voidwaitFor(long timeout) booleanwaitForProcessStarted(long duration, TimeUnit unit)
-
Constructor Details
-
CommandLine
-
-
Method Details
-
setEnvironmentVariables
Adds the specified environment variables.- Parameters:
environment- the variables to add- Throws:
IllegalArgumentException- if any value given is null (unsupported)
-
setEnvironmentVariable
Adds the specified environment variable.- Parameters:
name- the name of the environment variablevalue- the value of the environment variable- Throws:
IllegalArgumentException- if the value given is null (unsupported)
-
setDynamicLibraryPath
-
updateDynamicLibraryPath
-
getLibraryPathPropertyName
- Returns:
- The platform specific env property name which contains the library path.
-
executeAsync
public void executeAsync() -
execute
public void execute() -
waitForProcessStarted
-
waitFor
public void waitFor() -
waitFor
public void waitFor(long timeout) -
isSuccessful
public boolean isSuccessful() -
getExitCode
public int getExitCode() -
getStdOut
-
destroy
public int destroy()Destroy the current command.- Returns:
- The exit code of the command.
-
isRunning
public boolean isRunning()Check whether the current command is still executing.- Returns:
- true if the current command is still executing, false otherwise
-
setInput
-
setWorkingDirectory
-
toString
-
copyOutputTo
-
checkForError
public void checkForError()
-