com.caucho.xml.stream
Class NamespaceContextImpl

java.lang.Object
  extended by com.caucho.xml.stream.NamespaceContextImpl
All Implemented Interfaces:
javax.xml.namespace.NamespaceContext
Direct Known Subclasses:
NamespaceReaderContext, NamespaceWriterContext

public abstract class NamespaceContextImpl
extends java.lang.Object
implements javax.xml.namespace.NamespaceContext

Maintains a stack of namespace contexts


Field Summary
protected  java.util.ArrayList<com.caucho.xml.stream.NamespaceContextImpl.ElementBinding> _stack
           
protected  int _version
           
static L10N L
           
 
Method Summary
abstract  void declare(java.lang.String prefix, java.lang.String uri)
          declares a new namespace prefix in the current context
 int getDepth()
           
 javax.xml.namespace.QName getElementName()
           
 void pop()
          deletes the current context and enters its parent
 void push()
          Creates a new subcontext and enters it
protected abstract  void remove(java.lang.String prefix, java.lang.String uri)
           
 void setElementName(javax.xml.namespace.QName name)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.xml.namespace.NamespaceContext
getNamespaceURI, getPrefix, getPrefixes
 

Field Detail

L

public static final L10N L

_stack

protected final java.util.ArrayList<com.caucho.xml.stream.NamespaceContextImpl.ElementBinding> _stack

_version

protected int _version
Method Detail

getDepth

public int getDepth()

push

public void push()
Creates a new subcontext and enters it


pop

public void pop()
         throws XMLStreamException
deletes the current context and enters its parent

Throws:
XMLStreamException

setElementName

public void setElementName(javax.xml.namespace.QName name)

getElementName

public javax.xml.namespace.QName getElementName()

declare

public abstract void declare(java.lang.String prefix,
                             java.lang.String uri)
declares a new namespace prefix in the current context


remove

protected abstract void remove(java.lang.String prefix,
                               java.lang.String uri)