类 StaxResult

java.lang.Object
javax.xml.transform.sax.SAXResult
cn.taketoday.util.xml.StaxResult
所有已实现的接口:
Result

class StaxResult extends SAXResult
Implementation of the Result tagging interface for StAX writers. Can be constructed with an XMLEventConsumer or an XMLStreamWriter.

This class is necessary because there is no implementation of Source for StaxReaders in JAXP 1.3. There is a StAXResult in JAXP 1.4 (JDK 1.6), but this class is kept around for backwards compatibility reasons.

Even though StaxResult extends from SAXResult, calling the methods of SAXResult is not supported. In general, the only supported operation on this class is to use the ContentHandler obtained via SAXResult.getHandler() to parse an input source using an XMLReader. Calling setHandler(ContentHandler) or setLexicalHandler(LexicalHandler) will result in UnsupportedOperationExceptions.

从以下版本开始:
4.0
作者:
Arjen Poutsma
另请参阅:
  • 字段详细资料

  • 构造器详细资料

    • StaxResult

      public StaxResult(XMLEventWriter eventWriter)
      Construct a new instance of the StaxResult with the specified XMLEventWriter.
      参数:
      eventWriter - the XMLEventWriter to write to
    • StaxResult

      public StaxResult(XMLStreamWriter streamWriter)
      Construct a new instance of the StaxResult with the specified XMLStreamWriter.
      参数:
      streamWriter - the XMLStreamWriter to write to
  • 方法详细资料