Class: SyntaxTree::ERB::ErbClose
- Defined in:
- lib/syntax_tree/erb/nodes.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#closing ⇒ Object
readonly
Returns the value of attribute closing.
Attributes inherited from Element
Instance Method Summary collapse
- #accept(visitor) ⇒ Object
- #child_nodes ⇒ Object (also: #deconstruct)
- #deconstruct_keys(keys) ⇒ Object
-
#initialize(closing:, new_line:, location:) ⇒ ErbClose
constructor
A new instance of ErbClose.
Methods inherited from Element
Methods inherited from Node
#format, #pretty_print, #skip?, #without_new_line
Constructor Details
#initialize(closing:, new_line:, location:) ⇒ ErbClose
Returns a new instance of ErbClose.
375 376 377 378 |
# File 'lib/syntax_tree/erb/nodes.rb', line 375 def initialize(closing:, new_line:, location:) super(new_line: new_line, location: location) @closing = closing end |
Instance Attribute Details
#closing ⇒ Object (readonly)
Returns the value of attribute closing.
373 374 375 |
# File 'lib/syntax_tree/erb/nodes.rb', line 373 def closing @closing end |
Instance Method Details
#accept(visitor) ⇒ Object
380 381 382 |
# File 'lib/syntax_tree/erb/nodes.rb', line 380 def accept(visitor) visitor.visit_erb_close(self) end |
#child_nodes ⇒ Object Also known as: deconstruct
384 385 386 |
# File 'lib/syntax_tree/erb/nodes.rb', line 384 def child_nodes [] end |
#deconstruct_keys(keys) ⇒ Object
390 391 392 |
# File 'lib/syntax_tree/erb/nodes.rb', line 390 def deconstruct_keys(keys) super.merge(closing: closing) end |