public void addAttribute ( String attributeName , String attributeValue ) throws XmlModelException { String name = attributeName . trim ( ) ; String value = attributeValue . trim ( ) ; if ( attributesMap . containsKey ( name ) ) { throw new XmlModelException ( "Duplicate attribute: " + name ) ; } attributeNames . add ( name ) ; attributesMap . put ( name , new Attribute ( name , value ) ) ; }
Add a new element attribute