Class: ABNF::Parser::Node::Single

Inherits:
Object
  • Object
show all
Includes:
ABNF::Parser::Node
Defined in:
lib/abnf/parser/node.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from ABNF::Parser::Node

#==, #[], alternation, #child_count, #children, concatenation, #each, #octets, pattern_match, repetition, terminal

Constructor Details

#initialize(text, abnf) ⇒ Single

Returns a new instance of Single.



105
106
107
108
# File 'lib/abnf/parser/node.rb', line 105

def initialize text, abnf
  @text = text
  @abnf = abnf
end

Instance Attribute Details

#abnfObject (readonly)

Returns the value of attribute abnf.



102
103
104
# File 'lib/abnf/parser/node.rb', line 102

def abnf
  @abnf
end

#textObject (readonly)

Returns the value of attribute text.



103
104
105
# File 'lib/abnf/parser/node.rb', line 103

def text
  @text
end