Module: KDL::V1::Value::Methods
Instance Method Summary collapse
Instance Method Details
#==(other) ⇒ Object
13 14 15 16 17 |
# File 'lib/kdl/v1/value.rb', line 13 def ==(other) return self == other.value if other.is_a?(self.class.superclass) value == other end |
#to_s ⇒ Object
7 8 9 10 11 |
# File 'lib/kdl/v1/value.rb', line 7 def to_s return stringify_value unless type "(#{StringDumper.stringify_identifier type})#{stringify_value}" end |
#to_v1 ⇒ Object
23 24 25 |
# File 'lib/kdl/v1/value.rb', line 23 def to_v1 self end |
#to_v2 ⇒ Object
27 28 29 |
# File 'lib/kdl/v1/value.rb', line 27 def to_v2 self.class.superclass.new(value, format:, type:) end |
#version ⇒ Object
19 20 21 |
# File 'lib/kdl/v1/value.rb', line 19 def version 1 end |