Class: Backspin::CommandDiff::ComparisonSnapshot

Inherits:
Object
  • Object
show all
Defined in:
lib/backspin/command_diff.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(command_type:, data:) ⇒ ComparisonSnapshot

Returns a new instance of ComparisonSnapshot.



147
148
149
150
151
152
153
# File 'lib/backspin/command_diff.rb', line 147

def initialize(command_type:, data:)
  @command_type = command_type
  @data = data
  @stdout = data["stdout"]
  @stderr = data["stderr"]
  @status = data["status"]
end

Instance Attribute Details

#command_typeObject (readonly)

Returns the value of attribute command_type.



145
146
147
# File 'lib/backspin/command_diff.rb', line 145

def command_type
  @command_type
end

#statusObject (readonly)

Returns the value of attribute status.



145
146
147
# File 'lib/backspin/command_diff.rb', line 145

def status
  @status
end

#stderrObject (readonly)

Returns the value of attribute stderr.



145
146
147
# File 'lib/backspin/command_diff.rb', line 145

def stderr
  @stderr
end

#stdoutObject (readonly)

Returns the value of attribute stdout.



145
146
147
# File 'lib/backspin/command_diff.rb', line 145

def stdout
  @stdout
end

Instance Method Details

#to_hObject



155
156
157
# File 'lib/backspin/command_diff.rb', line 155

def to_h
  @data
end