Class: Rafflesia::SimulationGromacsPreflightData

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

Constant Summary collapse

HASH_ATTRS =
{
  command_count: :command_count,
  dynamic_input_count: :dynamic_input_count,
  dynamic_inputs: :dynamic_inputs,
  expected_outputs: :expected_outputs,
  has_all_inputs: :has_all_inputs,
  inventory_entry_count: :inventory_entry_count,
  is_runnable: :is_runnable,
  missing_input_count: :missing_input_count,
  missing_inputs: :missing_inputs,
  planned_outputs: :planned_outputs,
  required_input_count: :required_input_count,
  resolutions: :resolutions,
  resolved_input_count: :resolved_input_count,
  root_objects: :root_objects,
  runtime: :runtime,
  runtime_available: :runtime_available,
  schema_version: :schema_version,
  script: :script,
  stage_count: :stage_count,
  stages: :stages
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ SimulationGromacsPreflightData

Returns a new instance of SimulationGromacsPreflightData.



53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 53

def initialize(json)
  super()
  hash = self.class.normalize(json)
  @command_count = hash[:command_count]
  @dynamic_input_count = hash[:dynamic_input_count]
  @dynamic_inputs = (hash[:dynamic_inputs] || []).map { |item| item ? Rafflesia::SimulationGromacsFileRef.new(item) : nil }
  @expected_outputs = (hash[:expected_outputs] || []).map { |item| item ? Rafflesia::SimulationGromacsFileRef.new(item) : nil }
  @has_all_inputs = hash[:has_all_inputs]
  @inventory_entry_count = hash[:inventory_entry_count]
  @is_runnable = hash[:is_runnable]
  @missing_input_count = hash[:missing_input_count]
  @missing_inputs = (hash[:missing_inputs] || []).map { |item| item ? Rafflesia::SimulationGromacsFileRef.new(item) : nil }
  @planned_outputs = (hash[:planned_outputs] || []).map { |item| item ? Rafflesia::SimulationGromacsPlannedOutput.new(item) : nil }
  @required_input_count = hash[:required_input_count]
  @resolutions = (hash[:resolutions] || []).map { |item| item ? Rafflesia::SimulationGromacsInputResolution.new(item) : nil }
  @resolved_input_count = hash[:resolved_input_count]
  @root_objects = (hash[:root_objects] || []).map { |item| item ? Rafflesia::SimulationGromacsTextObject.new(item) : nil }
  @runtime = hash[:runtime] ? Rafflesia::SimulationRuntimeGromacsProbe.new(hash[:runtime]) : nil
  @runtime_available = hash[:runtime_available]
  @schema_version = hash[:schema_version]
  @script = hash[:script] ? Rafflesia::SimulationGromacsTextObject.new(hash[:script]) : nil
  @stage_count = hash[:stage_count]
  @stages = (hash[:stages] || []).map { |item| item ? Rafflesia::SimulationGromacsPreflightStage.new(item) : nil }
end

Instance Attribute Details

#command_countObject

Returns the value of attribute command_count.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def command_count
  @command_count
end

#dynamic_input_countObject

Returns the value of attribute dynamic_input_count.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def dynamic_input_count
  @dynamic_input_count
end

#dynamic_inputsObject

Returns the value of attribute dynamic_inputs.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def dynamic_inputs
  @dynamic_inputs
end

#expected_outputsObject

Returns the value of attribute expected_outputs.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def expected_outputs
  @expected_outputs
end

#has_all_inputsObject

Returns the value of attribute has_all_inputs.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def has_all_inputs
  @has_all_inputs
end

#inventory_entry_countObject

Returns the value of attribute inventory_entry_count.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def inventory_entry_count
  @inventory_entry_count
end

#is_runnableObject

Returns the value of attribute is_runnable.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def is_runnable
  @is_runnable
end

#missing_input_countObject

Returns the value of attribute missing_input_count.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def missing_input_count
  @missing_input_count
end

#missing_inputsObject

Returns the value of attribute missing_inputs.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def missing_inputs
  @missing_inputs
end

#planned_outputsObject

Returns the value of attribute planned_outputs.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def planned_outputs
  @planned_outputs
end

#required_input_countObject

Returns the value of attribute required_input_count.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def required_input_count
  @required_input_count
end

#resolutionsObject

Returns the value of attribute resolutions.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def resolutions
  @resolutions
end

#resolved_input_countObject

Returns the value of attribute resolved_input_count.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def resolved_input_count
  @resolved_input_count
end

#root_objectsObject

Returns the value of attribute root_objects.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def root_objects
  @root_objects
end

#runtimeObject

Returns the value of attribute runtime.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def runtime
  @runtime
end

#runtime_availableObject

Returns the value of attribute runtime_available.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def runtime_available
  @runtime_available
end

#schema_versionObject

Returns the value of attribute schema_version.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def schema_version
  @schema_version
end

#scriptObject

Returns the value of attribute script.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def script
  @script
end

#stage_countObject

Returns the value of attribute stage_count.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def stage_count
  @stage_count
end

#stagesObject

Returns the value of attribute stages.



31
32
33
# File 'lib/rafflesia/simulations/simulation_gromacs_preflight_data.rb', line 31

def stages
  @stages
end