Class: Rafflesia::SimulationGromacsPreflightStage

Inherits:
Types::BaseModel
  • Object
show all
Defined in:
lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb

Constant Summary collapse

HASH_ATTRS =
{
  command_index: :command_index,
  dynamic_input_count: :dynamic_input_count,
  index: :index,
  input_resolutions: :input_resolutions,
  inputs: :inputs,
  is_ready: :is_ready,
  line_number: :line_number,
  missing_input_count: :missing_input_count,
  outputs: :outputs,
  planned_outputs: :planned_outputs,
  raw: :raw,
  required_runtime: :required_runtime,
  runtime_is_available: :runtime_is_available,
  stage: :stage,
  subcommand: :subcommand
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ SimulationGromacsPreflightStage

Returns a new instance of SimulationGromacsPreflightStage.



43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 43

def initialize(json)
  super()
  hash = self.class.normalize(json)
  @command_index = hash[:command_index]
  @dynamic_input_count = hash[:dynamic_input_count]
  @index = hash[:index]
  @input_resolutions = (hash[:input_resolutions] || []).map { |item| item ? Rafflesia::SimulationGromacsInputResolution.new(item) : nil }
  @inputs = (hash[:inputs] || []).map { |item| item ? Rafflesia::SimulationGromacsFileRef.new(item) : nil }
  @is_ready = hash[:is_ready]
  @line_number = hash[:line_number]
  @missing_input_count = hash[:missing_input_count]
  @outputs = (hash[:outputs] || []).map { |item| item ? Rafflesia::SimulationGromacsFileRef.new(item) : nil }
  @planned_outputs = (hash[:planned_outputs] || []).map { |item| item ? Rafflesia::SimulationGromacsPlannedOutput.new(item) : nil }
  @raw = hash[:raw]
  @required_runtime = hash[:required_runtime]
  @runtime_is_available = hash[:runtime_is_available]
  @stage = hash[:stage]
  @subcommand = hash[:subcommand]
end

Instance Attribute Details

#command_indexObject

Returns the value of attribute command_index.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def command_index
  @command_index
end

#dynamic_input_countObject

Returns the value of attribute dynamic_input_count.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def dynamic_input_count
  @dynamic_input_count
end

#indexObject

Returns the value of attribute index.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def index
  @index
end

#input_resolutionsObject

Returns the value of attribute input_resolutions.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def input_resolutions
  @input_resolutions
end

#inputsObject

Returns the value of attribute inputs.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def inputs
  @inputs
end

#is_readyObject

Returns the value of attribute is_ready.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def is_ready
  @is_ready
end

#line_numberObject

Returns the value of attribute line_number.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def line_number
  @line_number
end

#missing_input_countObject

Returns the value of attribute missing_input_count.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def missing_input_count
  @missing_input_count
end

#outputsObject

Returns the value of attribute outputs.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def outputs
  @outputs
end

#planned_outputsObject

Returns the value of attribute planned_outputs.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def planned_outputs
  @planned_outputs
end

#rawObject

Returns the value of attribute raw.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def raw
  @raw
end

#required_runtimeObject

Returns the value of attribute required_runtime.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def required_runtime
  @required_runtime
end

#runtime_is_availableObject

Returns the value of attribute runtime_is_available.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def runtime_is_available
  @runtime_is_available
end

#stageObject

Returns the value of attribute stage.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def stage
  @stage
end

#subcommandObject

Returns the value of attribute subcommand.



26
27
28
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_stage.rb', line 26

def subcommand
  @subcommand
end