Class: Polites::Block::CodeBlock
- Inherits:
-
Polites::Block
- Object
- Node
- Polites::Block
- Polites::Block::CodeBlock
- Defined in:
- lib/polites/block/code_block.rb
Instance Attribute Summary collapse
-
#syntax ⇒ Object
readonly
Returns the value of attribute syntax.
Attributes inherited from Node
Instance Method Summary collapse
- #eql?(other) ⇒ Boolean
-
#initialize(children, syntax) ⇒ CodeBlock
constructor
A new instance of CodeBlock.
Methods inherited from Polites::Block
Methods inherited from Node
Constructor Details
#initialize(children, syntax) ⇒ CodeBlock
Returns a new instance of CodeBlock.
9 10 11 12 |
# File 'lib/polites/block/code_block.rb', line 9 def initialize(children, syntax) @syntax = syntax super(children) end |
Instance Attribute Details
#syntax ⇒ Object (readonly)
Returns the value of attribute syntax.
7 8 9 |
# File 'lib/polites/block/code_block.rb', line 7 def syntax @syntax end |
Instance Method Details
#eql?(other) ⇒ Boolean
14 15 16 |
# File 'lib/polites/block/code_block.rb', line 14 def eql?(other) super && syntax == other.syntax end |