Sha256: 78f16378ac7dea8e61227f7707efe535d51a8aa7c93d29c6a5cff96325b1e666

Contents?: true

Size: 559 Bytes

Versions: 8

Compression:

Stored size: 559 Bytes

Contents

module Metacrunch
  module Mab2
    class Document
      class Subfield

        attr_accessor :code
        attr_accessor :value

        def initialize(code = nil, value = nil)
          @code  = code
          @value = value
        end

        # ------------------------------------------------------------------------------
        # Serialization
        # ------------------------------------------------------------------------------

        def to_xml(builder)
          builder.subfield(value, code: code)
        end

      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
metacrunch-mab2-1.3.1 lib/metacrunch/mab2/document/subfield.rb
metacrunch-mab2-1.3.0 lib/metacrunch/mab2/document/subfield.rb
metacrunch-mab2-1.2.1 lib/metacrunch/mab2/document/subfield.rb
metacrunch-mab2-1.2.1-universal-java-1.8 lib/metacrunch/mab2/document/subfield.rb
metacrunch-mab2-1.2.0 lib/metacrunch/mab2/document/subfield.rb
metacrunch-mab2-1.1.2 lib/metacrunch/mab2/document/subfield.rb
metacrunch-mab2-1.1.1 lib/metacrunch/mab2/document/subfield.rb
metacrunch-mab2-1.1.0 lib/metacrunch/mab2/document/subfield.rb