Class: AgentSandbox::ExecResult

Inherits:
Object
  • Object
show all
Defined in:
lib/agent_sandbox/sandbox.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(stdout:, stderr:, status:) ⇒ ExecResult

Returns a new instance of ExecResult.



4
5
6
7
8
# File 'lib/agent_sandbox/sandbox.rb', line 4

def initialize(stdout:, stderr:, status:)
  @stdout = stdout
  @stderr = stderr
  @status = status
end

Instance Attribute Details

#statusObject (readonly)

Returns the value of attribute status.



3
4
5
# File 'lib/agent_sandbox/sandbox.rb', line 3

def status
  @status
end

#stderrObject (readonly)

Returns the value of attribute stderr.



3
4
5
# File 'lib/agent_sandbox/sandbox.rb', line 3

def stderr
  @stderr
end

#stdoutObject (readonly)

Returns the value of attribute stdout.



3
4
5
# File 'lib/agent_sandbox/sandbox.rb', line 3

def stdout
  @stdout
end

Instance Method Details

#success?Boolean

Returns:

  • (Boolean)


10
# File 'lib/agent_sandbox/sandbox.rb', line 10

def success? = status.zero?