@Override public boolean equals(Object obj){
  if (!(obj instanceof XmlNamespace)) {
    return false;
  }
  XmlNamespace other=(XmlNamespace)obj;
  if (alias == null) {
    return (other.alias == null) && uri.equals(other.uri);
  }
 else {
    return alias.equals(other.alias) && uri.equals(other.uri);
  }
}

@ Override public boolean equals ( Object obj ) { if ( ! ( obj instanceof XmlNamespace ) ) { return false ; } XmlNamespace other = ( XmlNamespace ) obj ; if ( alias == null ) { return ( other . alias == null ) && uri . equals ( other . uri ) ; } else { return alias . equals ( other . alias ) && uri . equals ( other . uri ) ; } }
returns true if the target object is a namespace instance that has a matching namespace uri and prefix ( if specified ) .
