public final class NamespaceBinding
extends java.lang.Object
Modifier and Type | Field | Description |
---|---|---|
static NamespaceBinding |
DEFAULT_UNDECLARATION |
|
static NamespaceBinding[] |
EMPTY_ARRAY |
|
static NamespaceBinding |
XML |
Constructor | Description |
---|---|
NamespaceBinding(java.lang.String prefix,
java.lang.String uri) |
Create a binding of a prefix to a URI
|
Modifier and Type | Method | Description |
---|---|---|
boolean |
equals(java.lang.Object obj) |
Test if this namespace binding is the same as another
|
java.lang.String |
getPrefix() |
Get the prefix part of the binding
|
java.lang.String |
getURI() |
Get the URI part of the binding
|
int |
hashCode() |
|
boolean |
isDefaultUndeclaration() |
Ask whether this is an undeclaration of the default prefix, that is, a namespace binding
corresponding to
xmlns="" |
boolean |
isXmlNamespace() |
Ask whether this is a binding for the XML namespace
|
static NamespaceBinding |
makeNamespaceBinding(java.lang.CharSequence prefix,
java.lang.CharSequence uri) |
Create a binding of a prefix to a URI.
|
public static final NamespaceBinding XML
public static final NamespaceBinding DEFAULT_UNDECLARATION
public static final NamespaceBinding[] EMPTY_ARRAY
public NamespaceBinding(java.lang.String prefix, java.lang.String uri)
prefix
- the prefix: either an NCName, or a zero-length string to bind the default namespace.
Must not be null.uri
- the namespace URI: either a URI, or a zero-length string to unbind the prefix. Must
not be null.public static NamespaceBinding makeNamespaceBinding(java.lang.CharSequence prefix, java.lang.CharSequence uri)
prefix
- the prefix: either an NCName, or a zero-length string to bind the default namespace.
Must not be null.uri
- the namespace URI: either a URI, or a zero-length string to unbind the prefix. Must
not be null.public java.lang.String getPrefix()
public java.lang.String getURI()
public boolean isXmlNamespace()
public boolean isDefaultUndeclaration()
xmlns=""
xmlns=""
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
obj
- the comparandpublic int hashCode()
hashCode
in class java.lang.Object