Class: SyntaxTree::RBS::Root
- Inherits:
-
Object
- Object
- SyntaxTree::RBS::Root
- Includes:
- Entrypoints
- Defined in:
- lib/syntax_tree/rbs/entrypoints.rb
Overview
This is the root node of the entire tree. It contains all of the top-level declarations within the file.
Instance Attribute Summary collapse
-
#declarations ⇒ Object
readonly
Returns the value of attribute declarations.
Instance Method Summary collapse
- #accept(visitor) ⇒ Object
-
#initialize(declarations) ⇒ Root
constructor
A new instance of Root.
Methods included from Entrypoints
Constructor Details
#initialize(declarations) ⇒ Root
Returns a new instance of Root.
25 26 27 |
# File 'lib/syntax_tree/rbs/entrypoints.rb', line 25 def initialize(declarations) @declarations = declarations end |
Instance Attribute Details
#declarations ⇒ Object (readonly)
Returns the value of attribute declarations.
23 24 25 |
# File 'lib/syntax_tree/rbs/entrypoints.rb', line 23 def declarations @declarations end |
Instance Method Details
#accept(visitor) ⇒ Object
29 30 31 |
# File 'lib/syntax_tree/rbs/entrypoints.rb', line 29 def accept(visitor) visitor.visit_root(self) end |