Class: ABNF::Parser::Node::Alternation
- Inherits:
-
Object
- Object
- ABNF::Parser::Node::Alternation
- Includes:
- ABNF::Parser::Node
- Defined in:
- lib/abnf/parser/node.rb
Instance Attribute Summary collapse
-
#abnf ⇒ Object
readonly
Returns the value of attribute abnf.
-
#match ⇒ Object
readonly
Returns the value of attribute match.
Instance Method Summary collapse
-
#initialize(match, abnf) ⇒ Alternation
constructor
A new instance of Alternation.
- #text ⇒ Object
Methods included from ABNF::Parser::Node
#==, #[], alternation, #child_count, #children, concatenation, #each, #octets, pattern_match, repetition, terminal
Constructor Details
#initialize(match, abnf) ⇒ Alternation
Returns a new instance of Alternation.
57 58 59 60 |
# File 'lib/abnf/parser/node.rb', line 57 def initialize match, abnf @abnf = abnf @match = match end |
Instance Attribute Details
#abnf ⇒ Object (readonly)
Returns the value of attribute abnf.
54 55 56 |
# File 'lib/abnf/parser/node.rb', line 54 def abnf @abnf end |
#match ⇒ Object (readonly)
Returns the value of attribute match.
55 56 57 |
# File 'lib/abnf/parser/node.rb', line 55 def match @match end |
Instance Method Details
#text ⇒ Object
62 63 64 |
# File 'lib/abnf/parser/node.rb', line 62 def text match.text end |