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