def add_attribute(atts, key, value)
      # Check for unique key and arrays of attributes
      if key == :class
        # If the key is already associated to an array, add the value to the
        # array, otherwise, create a new array or set it
        if atts[key]
          atts[key] << value
        else
          atts[key] = [value]
        end
      else
        atts[key] = value
      end
    end
def add_attribute(atts, key, value)
      # Check for unique key and arrays of attributes
      if key == :class
        # If the key is already associated to an array, add the value to the
        # array, otherwise, create a new array or set it
        if atts[key]
          atts[key] << value
        else
          atts[key] = [value]
        end
      else
        atts[key] = value
      end
    end
Deprecated @version 1.6.6

 When entering a definition model, we replace all the node types with their
 know definitions at definition call time.

 @param node_name [Symbol] Node identifier
 @param call_context [Node] Initial node call with its attributes

 def process_definition(node_name, call_context)
 model = [
   :def,
   node_name,
   {},
   [],
   call_context[@indent]
 ]

 model[@options] = {}.merge model[@options]
 model[@options][:call] = call_context

 Recursively map each child nodes to their definitions
 for the initial call node children and for the model
 children
 process_definition_child model[@options][:call]
 process_definition_child model
 model
 end

 Process definition children for the current node.

 @param node [Node] Callee node

 def process_definition_child(node)
   node[@children].map! do |child|
     if child[@type] == :node
       if !@definition_stack.include?(child[@value]) &&
          @definitions.key?(child[@value])
         process_definition child[@value], child
       else
         process_definition_child child if child[@children]
         child
       end
     else
       child
     end
   end
 end
 Helper method to create an array of values when an attribute is set
 multiple times. This happens unless the key is id, which is unique

 @param atts [Hash] Current node attributes hash
 @param key [Symbol] Attribute name
 @param value [String] Attribute value