Class: Refract::EnsureNode
- Defined in:
- lib/refract/nodes/ensure_node.rb
Instance Attribute Summary collapse
-
#statements ⇒ Object
Returns the value of attribute statements.
Instance Method Summary collapse
-
#initialize(prism_node: nil, statements:) ⇒ EnsureNode
constructor
A new instance of EnsureNode.
Methods inherited from Node
#accept, #copy, #start_line, #type, type
Constructor Details
#initialize(prism_node: nil, statements:) ⇒ EnsureNode
Returns a new instance of EnsureNode.
5 6 7 8 9 |
# File 'lib/refract/nodes/ensure_node.rb', line 5 def initialize(prism_node: nil, statements:) @prism_node = prism_node => Prism::Node | nil @statements = statements freeze end |
Instance Attribute Details
#statements ⇒ Object
Returns the value of attribute statements.
11 12 13 |
# File 'lib/refract/nodes/ensure_node.rb', line 11 def statements @statements end |