oracle.cabo.share.xml
Class NamespaceURI
java.lang.Object
|
+--oracle.cabo.share.xml.NamespaceURI
- public final class NamespaceURI
- extends java.lang.Object
Utility class to parse a string of the form
namespacePrefix:name
Constructor Summary |
NamespaceURI(java.lang.String namespace,
java.lang.String name)
|
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
NamespaceURI
public NamespaceURI(java.lang.String namespace,
java.lang.String name)
getNamespace
public java.lang.String getNamespace()
- Returns:
- the namespace of this URI
getName
public java.lang.String getName()
- Returns:
- the name portion of this URI
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in class java.lang.Object
hashCode
public int hashCode()
- Overrides:
hashCode
in class java.lang.Object
create
public static NamespaceURI create(ParseContext context,
java.lang.String namespaceURI,
java.lang.String defaultNamespace)
- parses a string of the form
namespacePrefix:name
- Parameters:
context
- the context to look up namespace prefixes and grab the
ErrorLog fromnamespaceURI
- the string to parse. If there is no namespace prefix
in this string, a private, default namespace will be used.defaultNamespace
- the default namespace to use, if no prefix was
provided in namespaceURI
.- Returns:
- an object from which you can pull out the namespace and the
name, or null if the string couldn't be parsed (in which case an error
will be logged in the ErrorLog (see
ParseContext.getErrorLog()
).
Copyright © 2002,2003, Oracle. All Rights Reserved.