Class WindowsRemoteCommandResult

java.lang.Object
org.metricshub.winrm.WindowsRemoteCommandResult

public class WindowsRemoteCommandResult extends Object
The result of a command run by the legacy WinRMCommandExecutor: its output, exit code and execution time.
  • Constructor Details

    • WindowsRemoteCommandResult

      public WindowsRemoteCommandResult(String stdout, String stderr, float executionTime, int statusCode)
      Command Result constructor
      Parameters:
      stdout - The stdout of the command
      stderr - The stderr of the command
      executionTime - The execution time of the command in seconds
      statusCode - The command return status code
  • Method Details

    • getStdout

      public String getStdout()
      Get the stdout of the command.
      Returns:
      the standard output of the command
    • getStderr

      public String getStderr()
      Get the stderr of the command.
      Returns:
      the standard error of the command
    • getExecutionTime

      public float getExecutionTime()
      Get the execution time of the command in seconds.
      Returns:
      the execution time, in seconds
    • getStatusCode

      public int getStatusCode()
      Get the return status code of the command
      Returns:
      the exit code of the command
    • toString

      public String toString()
      Overrides:
      toString in class Object