lib/skemata/node.rb
#
# Decorate the node with a new property (as delegated by method_missing)
#
# @param name [Symbol] Key name
# @param *args [Array] Varargs for attributes describing key
# @param &block [Proc] Body for a child node, if present
#
Decorate the node with a new property (as delegated by method_missing)
Decorate the node with a new property ( as delegated by method_missing )
def decorate(name, *args, &block)
      return route_block(name, *args, &block) if block.present?
      data[attify_token(name)] = extract(args.first || name.to_sym)
    end
def decorate ( name , * args , & block ) return route_block ( name , * args , & block ) if block . present? data [ attify_token ( name ) ] = extract ( args . first || name . to_sym ) end
Decorate the node with a new property (as delegated by method_missing)
Decorate the node with a new property ( as delegated by method_missing )
# Draw another node # Or populate the hash
name
None
args
block
*args
Varargs for attributes describing key
Varargs for attributes describing key
&block
Body for a child node, if present
Body for a child node if present