Class: FastHaml::Ast::Element

Inherits:
Struct
  • Object
show all
Includes:
HasChildren
Defined in:
lib/fast_haml/ast.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from HasChildren

#<<

Constructor Details

#initializeElement

Returns a new instance of Element.



34
35
36
37
38
39
40
41
42
# File 'lib/fast_haml/ast.rb', line 34

def initialize(*)
  super
  self.static_class ||= ''
  self.static_id ||= ''
  self.attributes ||= ''
  self.self_closing ||= false
  self.nuke_inner_whitespace ||= false
  self.nuke_outer_whitespace ||= false
end

Instance Attribute Details

#attributesObject

Returns the value of attribute attributes

Returns:

  • (Object)

    the current value of attributes



21
22
23
# File 'lib/fast_haml/ast.rb', line 21

def attributes
  @attributes
end

#childrenObject

Returns the value of attribute children

Returns:

  • (Object)

    the current value of children



21
22
23
# File 'lib/fast_haml/ast.rb', line 21

def children
  @children
end

#nuke_inner_whitespaceObject

Returns the value of attribute nuke_inner_whitespace

Returns:

  • (Object)

    the current value of nuke_inner_whitespace



21
22
23
# File 'lib/fast_haml/ast.rb', line 21

def nuke_inner_whitespace
  @nuke_inner_whitespace
end

#nuke_outer_whitespaceObject

Returns the value of attribute nuke_outer_whitespace

Returns:

  • (Object)

    the current value of nuke_outer_whitespace



21
22
23
# File 'lib/fast_haml/ast.rb', line 21

def nuke_outer_whitespace
  @nuke_outer_whitespace
end

#oneline_childObject

Returns the value of attribute oneline_child

Returns:

  • (Object)

    the current value of oneline_child



21
22
23
# File 'lib/fast_haml/ast.rb', line 21

def oneline_child
  @oneline_child
end

#self_closingObject

Returns the value of attribute self_closing

Returns:

  • (Object)

    the current value of self_closing



21
22
23
# File 'lib/fast_haml/ast.rb', line 21

def self_closing
  @self_closing
end

#static_classObject

Returns the value of attribute static_class

Returns:

  • (Object)

    the current value of static_class



21
22
23
# File 'lib/fast_haml/ast.rb', line 21

def static_class
  @static_class
end

#static_idObject

Returns the value of attribute static_id

Returns:

  • (Object)

    the current value of static_id



21
22
23
# File 'lib/fast_haml/ast.rb', line 21

def static_id
  @static_id
end

#tag_nameObject

Returns the value of attribute tag_name

Returns:

  • (Object)

    the current value of tag_name



21
22
23
# File 'lib/fast_haml/ast.rb', line 21

def tag_name
  @tag_name
end