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