The prefix is included in QName to retain lexical
information when present in an XML input source. The prefix is
NOT used in QName.equals(Object) or to compute the QName.hashCode(). Equality and the hash code are defined using
only the Namespace URI and local part.

Causes the current thread to wait until another thread invokes the
notify() method or the
notifyAll() method for this object, or
some other thread interrupts the current thread, or a certain
amount of real time has elapsed.

Public methods

equals

If the Object to be tested is not a
QName or is null, then this method
returns false.

Two QNames are considered equal if and only if
both the Namespace URI and local part are equal. This method
uses String.equals() to check equality of the
Namespace URI and local part. The prefix is
NOT used to determine equality.

getNamespaceURI

getPrefix

The prefix assigned to a QName might
NOT be valid in a different
context. For example, a QName may be assigned a
prefix in the context of parsing a document but that prefix may
be invalid in the context of a different document.

toString

The commonly accepted way of representing a QName
as a String was defined
by James Clark. Although this is not a standard
specification, it is in common use, e.g. setParameter(String, Object).
This implementation represents a QName as:
"{" + Namespace URI + "}" + local part. If the Namespace URI
.equals(XMLConstants.NULL_NS_URI), only the
local part is returned. An appropriate use of this method is
for debugging or logging for human consumption.

Note the prefix value is NOT
returned as part of the String representation.

The commonly accepted way of representing a QName
as a String was defined
by James Clark. Although this is not a standard
specification, it is in common use, e.g. setParameter(String, Object).
This implementation parses a String formatted
as: "{" + Namespace URI + "}" + local part. If the Namespace
URI .equals(XMLConstants.NULL_NS_URI), only the
local part should be provided.