Class: Mspire::Mzml::InstrumentConfiguration
- Inherits:
-
Object
- Object
- Mspire::Mzml::InstrumentConfiguration
- Extended by:
- List
- Includes:
- CV::Paramable
- Defined in:
- lib/mspire/mzml/instrument_configuration.rb
Instance Attribute Summary collapse
-
#components ⇒ Object
a list of Source, Analyzer, Detector objects.
-
#id ⇒ Object
(required) the id that this guy can be referenced from.
-
#software ⇒ Object
a single software object associated with the instrument.
Attributes included from CV::Paramable
#cv_params, #ref_param_groups, #user_params
Instance Method Summary collapse
-
#initialize(id, components = [], opts = {params: []}) ⇒ InstrumentConfiguration
constructor
A new instance of InstrumentConfiguration.
- #to_xml(builder) ⇒ Object
Methods included from List
Methods included from CV::Paramable
#accessionable_params, #describe!, #describe_many!, #fetch, #fetch_by_accession, #param?, #param_by_accession, #params, #params?
Constructor Details
#initialize(id, components = [], opts = {params: []}) ⇒ InstrumentConfiguration
Returns a new instance of InstrumentConfiguration.
19 20 21 22 23 |
# File 'lib/mspire/mzml/instrument_configuration.rb', line 19 def initialize(id, components=[], opts={params: []}) super(opts) @id = id @components = components end |
Instance Attribute Details
#components ⇒ Object
a list of Source, Analyzer, Detector objects
14 15 16 |
# File 'lib/mspire/mzml/instrument_configuration.rb', line 14 def components @components end |
#id ⇒ Object
(required) the id that this guy can be referenced from
11 12 13 |
# File 'lib/mspire/mzml/instrument_configuration.rb', line 11 def id @id end |
#software ⇒ Object
a single software object associated with the instrument
17 18 19 |
# File 'lib/mspire/mzml/instrument_configuration.rb', line 17 def software @software end |
Instance Method Details
#to_xml(builder) ⇒ Object
25 26 27 28 29 30 31 32 |
# File 'lib/mspire/mzml/instrument_configuration.rb', line 25 def to_xml(builder) builder.instrumentConfiguration(id: @id) do |inst_conf_n| super(builder) Mspire::Mzml::Component.list_xml(components, inst_conf_n) inst_conf_n.softwareRef(ref: @software.id) if @software end builder end |