Xerces2 Implementation: Class XMLDocumentFragmentScannerImpl.ElementStack

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.xerces.impl
Class XMLDocumentFragmentScannerImpl.ElementStack

    java.lang.Object
      |
      +--org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.ElementStack

Enclosing class:
  XMLDocumentFragmentScannerImpl

protected static class XMLDocumentFragmentScannerImpl.ElementStack
extends java.lang.Object

Element stack. This stack operates without synchronization, error checking, and it re-uses objects instead of throwing popped items away.

Author:
  Andy Clark, IBM

Field Summary
`protected org.apache.xerces.xni.QName[]` | `fElements` The stack data.
`protected int` | `fSize` The size of the stack.

Constructor Summary
`XMLDocumentFragmentScannerImpl.ElementStack()` Default constructor.

Method Summary
`void` | `clear()` Clears the stack without throwing away existing QName objects.
`void` | `popElement(org.apache.xerces.xni.QName element)` Pops an element off of the stack by setting the values of the specified QName.
`org.apache.xerces.xni.QName` | `pushElement(org.apache.xerces.xni.QName element)` Pushes an element on the stack.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### fElements

    protected org.apache.xerces.xni.QName[] fElements

  The stack data.

### fSize

    protected int fSize

  The size of the stack.

Constructor Detail

### XMLDocumentFragmentScannerImpl.ElementStack

    public XMLDocumentFragmentScannerImpl.ElementStack()

  Default constructor.

Method Detail

### pushElement

    public org.apache.xerces.xni.QName pushElement(org.apache.xerces.xni.QName element)

  Pushes an element on the stack.

  Note: The QName values are copied into the stack. In other words, the caller does not orphan the element to the stack. Also, the QName object returned is not orphaned to the caller. It should be considered read-only.

  Parameters:
    `element` - The element to push onto the stack.
  Returns:
    Returns the actual QName object that stores the

### popElement

    public void popElement(org.apache.xerces.xni.QName element)

  Pops an element off of the stack by setting the values of the specified QName.

  Note: The object returned is not orphaned to the caller. Therefore, the caller should consider the object to be read-only.

### clear

    public void clear()

  Clears the stack without throwing away existing QName objects.

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 1999-2007 The Apache Software Foundation. All Rights Reserved.