Sha256: a3b57438b2d428c54a6f9438e4ede447af6a2246e346b7010825c6acd32b2396

Contents?: true

Size: 581 Bytes

Versions: 11

Compression:

Stored size: 581 Bytes

Contents

require 'ms/mzml/list'

module MS
  class Mzml
    class DataProcessing

      attr_accessor :id, :processing_methods

      # yields self if given a block
      def initialize(id, processing_methods=[], &block)
        @id, @processing_methods = id, processing_methods
        block.call(self) if block
      end

      def to_xml(builder)
        builder.dataProcessing( id: @id ) do |dp_n|
          processing_methods.each do |proc_method|
            proc_method.to_xml(dp_n)
          end
        end
        builder
      end

      extend(MS::Mzml::List)
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
mspire-0.6.26 lib/ms/mzml/data_processing.rb
mspire-0.6.25 lib/ms/mzml/data_processing.rb
mspire-0.6.24 lib/ms/mzml/data_processing.rb
mspire-0.6.22 lib/ms/mzml/data_processing.rb
mspire-0.6.21 lib/ms/mzml/data_processing.rb
mspire-0.6.20 lib/ms/mzml/data_processing.rb
mspire-0.6.19 lib/ms/mzml/data_processing.rb
mspire-0.6.18 lib/ms/mzml/data_processing.rb
mspire-0.6.12 lib/ms/mzml/data_processing.rb
mspire-0.6.11 lib/ms/mzml/data_processing.rb
mspire-0.6.9 lib/ms/mzml/data_processing.rb