public void clean(){
  for (int i=theAtts.getLength() - 1; i >= 0; i--) {
    String name=theAtts.getLocalName(i);
    if (theAtts.getValue(i) == null || name == null || name.length() == 0) {
      theAtts.removeAttribute(i);
      continue;
    }
  }
}

public void clean ( ) { for ( int i = theAtts . getLength ( ) - 1 ; i >= 0 ; i -- ) { String name = theAtts . getLocalName ( i ) ; if ( theAtts . getValue ( i ) == null || name == null || name . length ( ) == 0 ) { theAtts . removeAttribute ( i ) ; continue ; } } }
clean the attributes of this element . attributes with null name ( the name was ill - formed ) or null value ( the attribute was present in the element type but not in this actual element ) are removed .
