class Curly::Parser::Block

Attributes

component[R]
nodes[R]
type[R]

Public Class Methods

new(type, component, nodes = []) click to toggle source
# File lib/curly/parser.rb, line 75
def initialize(type, component, nodes = [])
  @type, @component, @nodes = type, component, nodes
end

Public Instance Methods

<<(node) click to toggle source
# File lib/curly/parser.rb, line 89
def <<(node)
  @nodes << node
end
==(other) click to toggle source
# File lib/curly/parser.rb, line 93
def ==(other)
  other.type == type &&
    other.component == component &&
    other.nodes == nodes
end
closed_by?(component) click to toggle source
# File lib/curly/parser.rb, line 79
def closed_by?(component)
  self.component.name == component.name &&
    self.component.identifier == component.identifier &&
    self.component.contexts == component.contexts
end
to_s() click to toggle source
# File lib/curly/parser.rb, line 85
def to_s
  component.to_s
end