Class: JSON5::NumberNode
Instance Attribute Summary collapse
-
#classification ⇒ Object
readonly
Returns the value of attribute classification.
-
#sign ⇒ Object
readonly
Returns the value of attribute sign.
Attributes inherited from Node
#end_byte, #leading_trivia, #raw_span, #source, #start_byte, #trailing_trivia, #type
Instance Method Summary collapse
-
#initialize(classification:, sign:, **attributes) ⇒ NumberNode
constructor
A new instance of NumberNode.
Methods inherited from Node
Constructor Details
#initialize(classification:, sign:, **attributes) ⇒ NumberNode
Returns a new instance of NumberNode.
39 40 41 42 43 |
# File 'lib/json5/document_nodes.rb', line 39 def initialize(classification:, sign:, **attributes) @classification = classification @sign = sign super(type: :number, **attributes) end |
Instance Attribute Details
#classification ⇒ Object (readonly)
Returns the value of attribute classification.
37 38 39 |
# File 'lib/json5/document_nodes.rb', line 37 def classification @classification end |
#sign ⇒ Object (readonly)
Returns the value of attribute sign.
37 38 39 |
# File 'lib/json5/document_nodes.rb', line 37 def sign @sign end |