Method: REXML::Attributes#add
- Defined in:
- lib/rexml/element.rb
#add(attribute) ⇒ Object Also known as: <<
Adds an attribute, overriding any existing attribute by the same name. Namespaces are significant.
- attribute
-
An Attribute
1202 1203 1204 |
# File 'lib/rexml/element.rb', line 1202 def add( attribute ) self[attribute.name] = attribute end |