def ox_elem(name,o={},&block)
      new_elem =  Elem.new(name, o.reverse_merge(:tag_proc => @tag_proc),&block)
      @ox_elems << new_elem
      ox_accessor new_elem.accessor
    end
def ox_elem(name,o={},&block)
      new_elem =  Elem.new(name, o.reverse_merge(:tag_proc => @tag_proc),&block)
      @ox_elems << new_elem
      ox_accessor new_elem.accessor
    end
Declares a reference to a certain xml element or a typed collection of elements.

 == Sym Option
 [sym] Symbol representing the name of the accessor.

 === Default naming
 This name will be the default node searched for, if no other is declared. For example:

  ox_elem :bob
  ox_elem :pony

 are equivalent to:

  ox_elem :bob, :from => 'bob'
  ox_elem :pony, :from => 'pony'

 === Boolean attributes
 If the name ends in a ?, OxMlk will attempt to coerce the value to true or false,
 with true, yes, t and 1 mapping to true and false, no, f and 0 mapping
 to false, as shown below:

  ox_elem :desirable?
  ox_attr :bizzare?, :from => 'BIZZARE'

  x = #from_xml(%{
    <object BIZZARE="1">
      <desirable>False</desirable>
    </object>
  })

  x.desirable?
  => false
  x.bizzare?
  => true

 When a block is provided the value will be passed to the block
 where unexpected values can be handled. If no block is provided
 the unexpected value will be returned.

  #from_xml(%{
    <object>
      <desirable>Dunno</desirable>
    </object>
  }).desirable?
  => "Dunno"

  ox_elem :strange? do |val|
    val.upcase
  end

  #from_xml(%{
    <object>
      <strange>Dunno</strange>
    </object>
  }).strange?
  => "DUNNO"

 == Blocks
 You may also pass a block which manipulates the associated parsed value.

  class Muffins
    include OxMlk

    ox_elem(:count, :from => 'bakers_dozens') {|val| val.first.to_i * 13 }
  end

 Blocks are always passed an Array and are the last thing to manipulate the XML.
 The array will include all elements already manipulated by anything passed to
 the :as option. If the :as option is an Array and no block is passed then the
 Array is returned unmodified. If the :as option is nil or is not an Array then
 only the first element is

 == Options
 === :as
 ==== Basic Types
 Allows you to specify one of several basic types to return the value as. For example

  ox_elem :count, :as => Integer

 is equivalent to:

  ox_elem(:count) {|val| Integer(val.first) unless val.first.empty?}

 Such block shorthands for Integer, Float, String, Symbol and Time
 are currently available.

 To reference many elements, put the desired type in a literal array. e.g.:

   ox_elem :counts, :as => [Integer]

 Even an array of text nodes can be specified with :as => []

   ox_elem :quotes, :as => []

 === Other OxMlk Classes
 Declares an accessor that represents another OxMlk class as child XML element
 (one-to-one or composition) or array of child elements (one-to-many or
 aggregation) of this type. Default is one-to-one. For one-to-many, simply pass the class
 as the only element in an array. You can also put several OxMlk classes in an Array that
 will act like a polymorphic one-to-many association.

 Composition example:
  <book>
   <publisher>
     <name>Pragmatic Bookshelf</name>
   </publisher>
  </book>

 Can be mapped using the following code:
   class Book
     include OxMlk
     ox_elem :publisher, :as => Publisher
   end

 Aggregation example:
  <library>
   <books>
    <book/>
    <book/>
   </books>
  </library>

 Can be mapped using the following code:
   class Library
     include OxMlk
     ox_elem :books, :as => [Book], :in => 'books'
   end

 If you don't have the <books> tag to wrap around the list of <book> tags:
   <library>
     <name>Ruby books</name>
     <book/>
     <book/>
   </library>

 You can skip the wrapper argument:
    ox_elem :books, :as => [Book]

 ==== Hash
 Unlike ROXML, OxMlk doesn't do anything special for hashes. However OxMlk
 applies :as to each element and the block once to the Array of elements.
 This means OxMlk can support setting hashes but it is more of a manual process.
 I am looking for a easier method but for now here are a few examples:

 ===== Hash of element contents
 For xml such as this:

    <dictionary>
      <definition>
        <word/>
        <meaning/>
      </definition>
      <definition>
        <word/>
        <meaning/>
      </definition>
    </dictionary>

 This is actually one of the more complex ones. It uses the :raw keyword to pass the block an array of LibXML::XML::Nodes
   ox_elem(:definitions, :from => 'definition', :as => [:raw]) do |vals|
     Hash[*vals.map {}|val| [val.search('word').content,val.search('meaning').content]}.flatten]
   end

 ===== Hash of :content
 For xml such as this:

   <dictionary>
     <definition word="quaquaversally">adjective: (of a geological formation) sloping downward from the center in all directions.</definition>
     <definition word="tergiversate">To use evasions or ambiguities; equivocate.</definition>
   </dictionary>

 This one can also be accomplished with the :raw keyword and a fancy block.
   ox_elem(:definitions, :from => 'definition', :as => [:raw]) {|x| Hash[*x.map {|val| [val['word'],val.content] }.flatten]}

 ===== Hash of :name
 For xml such as this:

    <dictionary>
      <quaquaversally>adjective: (of a geological formation) sloping downward from the center in all directions.</quaquaversally>
      <tergiversate>To use evasions or ambiguities; equivocate.</tergiversate>
    </dictionary>

 This one requires some fancy xpath in :from to grab all the elements
    ox_elem(:definitions, :from => './*', :as => [:raw]) {|x| Hash[*x.map {|val| [val.name,val.content] }.flatten]}

 === :from
 The name by which the xml value will be found in XML. Default is sym.

 This value may also include XPath notation.

 ==== :from => :content
 When :from is set to :content, this refers to the content of the current node,
 rather than a sub-node. It is equivalent to :from => '.'

 Example:
  class Contributor
    ox_elem :name, :from => :content
    ox_attr :role
  end

 To map:
  <contributor role="editor">James Wick</contributor>

 === :in
 An optional name of a wrapping tag for this XML accessor.
 This can include other xpath values, which will be joined with :from with a '/'