Interface StAXStreamProcessor

  • All Known Implementing Classes:
    AbstractStAXStreamProcessor

    public interface StAXStreamProcessor
    This interface provides a base support for the XMLOutputter2.

    People who want to create a custom XMLOutputProcessor for XMLOutputter are able to implement this interface with the following notes and restrictions:

    1. The XMLOutputter will call one, and only one of the process(XMLStreamWriter,Format,*) methods each time the XMLOutputter is requested to output some JDOM content. It is thus safe to assume that a process(XMLStreamWriter,Format,*) method can set up any infrastructure needed to process the content, and that the XMLOutputter will not re-call that method, or some other process(XMLStreamWriter,Format,*) method for the same output sequence.
    2. The process methods should be thread-safe and reentrant: The same process(XMLStreamWriter,Format,*) method may (will) be called concurrently from different threads.

    The AbstractXMLOutputProcessor class is a full implementation of this interface and is fully customisable. People who want a custom XMLOutputter are encouraged to extend the AbstractXMLOutputProcessor rather than do a full re-implementation of this interface.

    Since:
    JDOM2
    See Also:
    XMLOutputter2, AbstractXMLOutputProcessor