NASA World Wind

gov.nasa.worldwind.util
Class BasicNamespaceContext

java.lang.Object
  extended by gov.nasa.worldwind.util.BasicNamespaceContext
All Implemented Interfaces:
NamespaceContext
Direct Known Subclasses:
WMSNamespaceContext

public class BasicNamespaceContext
extends Object
implements NamespaceContext

BasicNamespaceContext provides a mutable implementation of the NamespaceContext interface.


Field Summary
static String XLINK_NS_PREFIX
           
static String XLINK_NS_URI
           
 
Constructor Summary
BasicNamespaceContext()
          Sole constructor for BasicNamespaceContext.
 
Method Summary
 void addNamespace(String prefix, String namespaceURI)
          Adds a namepsace binding to this XML namespace context.
 String getNamespaceURI(String prefix)
          
 String getPrefix(String namespaceURI)
          
 Iterator getPrefixes(String namespaceURI)
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

XLINK_NS_PREFIX

public static final String XLINK_NS_PREFIX
See Also:
Constant Field Values

XLINK_NS_URI

public static final String XLINK_NS_URI
See Also:
Constant Field Values
Constructor Detail

BasicNamespaceContext

public BasicNamespaceContext()
Sole constructor for BasicNamespaceContext. This configures the following namespaces:
PrefixURI
xmlhttp://www.w3.org/XML/1998/namespace
xmlnshttp://www.w3.org/2000/xmlns/
xlinkhttp://www.w3.org/1999/xlink

Method Detail

addNamespace

public void addNamespace(String prefix,
                         String namespaceURI)
Adds a namepsace binding to this XML namespace context. The specified URI is bound to the specified prefix.

Parameters:
prefix - the namespace prefix.
namespaceURI - the namespace URI.
Throws:
IllegalArgumentException - if either the prefix or the namepsace URI are null.

getNamespaceURI

public String getNamespaceURI(String prefix)

Specified by:
getNamespaceURI in interface NamespaceContext

getPrefix

public String getPrefix(String namespaceURI)

Specified by:
getPrefix in interface NamespaceContext

getPrefixes

public Iterator getPrefixes(String namespaceURI)

Specified by:
getPrefixes in interface NamespaceContext

NASA World Wind