Sha256: 6e17cd5c294ec5b47b9fcdfb6634c117b554b39f552e0d12cd7199cdca0037a2

Contents?: true

Size: 928 Bytes

Versions: 57

Compression:

Stored size: 928 Bytes

Contents

module BELParser
  module Resource
    # Value
    module Value

      def dataset
        raise NotImplementedError, "#{__method__} is not implemented."
      end

      def name
        raise NotImplementedError, "#{__method__} is not implemented."
      end

      def identifier
        nil
      end

      def title
        nil
      end

      def synonyms
        []
      end

      def encodings
        raise NotImplementedError, "#{__method__} is not implemented."
      end

      def <=>(another_value)
        name <=> another_value.name
      end

      def hash
        [dataset, name, encodings].hash
      end

      def ==(another_value)
        return false if another_value == nil
        dataset   == another_value.dataset &&
        name      == another_value.name &&
        encodings == another_value.encodings
      end
      alias :eql? :'=='

      def to_s
        name
      end
    end
  end
end

Version data entries

57 entries across 57 versions & 1 rubygems

Version Path
bel_parser-1.1.6-java lib/bel_parser/resource/value.rb
bel_parser-1.1.6 lib/bel_parser/resource/value.rb
bel_parser-1.1.5 lib/bel_parser/resource/value.rb
bel_parser-1.1.4-java lib/bel_parser/resource/value.rb
bel_parser-1.1.4 lib/bel_parser/resource/value.rb
bel_parser-1.1.3-java lib/bel_parser/resource/value.rb
bel_parser-1.1.3 lib/bel_parser/resource/value.rb
bel_parser-1.1.2-java lib/bel_parser/resource/value.rb
bel_parser-1.1.2 lib/bel_parser/resource/value.rb
bel_parser-1.1.1-java lib/bel_parser/resource/value.rb
bel_parser-1.1.1 lib/bel_parser/resource/value.rb
bel_parser-1.0.8-java lib/bel_parser/resource/value.rb
bel_parser-1.0.8 lib/bel_parser/resource/value.rb
bel_parser-1.0.7-java lib/bel_parser/resource/value.rb
bel_parser-1.0.7 lib/bel_parser/resource/value.rb
bel_parser-1.0.6-java lib/bel_parser/resource/value.rb
bel_parser-1.0.6 lib/bel_parser/resource/value.rb
bel_parser-1.0.5-java lib/bel_parser/resource/value.rb
bel_parser-1.0.5 lib/bel_parser/resource/value.rb
bel_parser-1.0.4-java lib/bel_parser/resource/value.rb