"<country code='de'>Germany</country>"# definition of the 'code' attribute within the class
attribute:code,String
Parameters:
name(Symbol)
—
the name of the accessor that is created
type(String, Class)
—
the class name of the name of the class whcih the object will be converted upon parsing
options(Hash)(defaults to: {})
—
additional parameters to send to the relationship
55
56
57
58
59
# File 'lib/xmlmapper.rb', line 55defattribute(name,type,options={})attribute=Attribute.new(name,type,options)@attributes[name]=attributeattr_accessorattribute.method_name.internend