Class: Foxtail::Syntax::Parser::AST::Pattern
- Inherits:
-
SyntaxNode
- Object
- BaseNode
- SyntaxNode
- Foxtail::Syntax::Parser::AST::Pattern
- Defined in:
- lib/foxtail/syntax/parser/ast/pattern.rb
Overview
Represents a message or term value pattern consisting of text elements and placeables (expressions within braces)
Instance Attribute Summary collapse
-
#elements ⇒ Object
Returns the value of attribute elements.
Attributes inherited from SyntaxNode
Attributes inherited from BaseNode
Instance Method Summary collapse
- #children ⇒ Object
-
#initialize(elements) ⇒ Pattern
constructor
A new instance of Pattern.
Methods inherited from SyntaxNode
Methods inherited from BaseNode
Constructor Details
#initialize(elements) ⇒ Pattern
Returns a new instance of Pattern.
12 13 14 15 |
# File 'lib/foxtail/syntax/parser/ast/pattern.rb', line 12 def initialize(elements) super() @elements = elements end |
Instance Attribute Details
#elements ⇒ Object
Returns the value of attribute elements.
10 11 12 |
# File 'lib/foxtail/syntax/parser/ast/pattern.rb', line 10 def elements @elements end |
Instance Method Details
#children ⇒ Object
17 |
# File 'lib/foxtail/syntax/parser/ast/pattern.rb', line 17 def children = elements |