Package io.gem.api

Class SshResponse

java.lang.Object
io.gem.api.SshResponse

public final class SshResponse extends Object
Mutable holder for SSH command execution streams and exit code.

Used by SshUtils.runCommand(org.apache.sshd.client.session.ClientSession, String, long, SshResponse) to channel stdout/stderr and record the return code.

  • Field Details

    • errOutputStream

      public final OutputStream errOutputStream
      OutputStream errOutputStream.
    • stdOutputStream

      public final OutputStream stdOutputStream
      OutputStream stdOutputStream.
    • returnCode

      public int returnCode
      int returnCode.
  • Constructor Details

    • SshResponse

      public SshResponse(boolean stdout)
      Create response streams.
      Parameters:
      stdout - if true, allocate a buffer for stdout; otherwise discard to a null stream