Class Stax2Util

  • All Implemented Interfaces:
    javax.xml.stream.XMLStreamConstants

    public final class Stax2Util
    extends java.lang.Object
    implements javax.xml.stream.XMLStreamConstants
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  Stax2Util.ByteAggregator
      Helper class for efficiently reading and aggregating variable length byte content.
      static class  Stax2Util.TextBuffer
      Helper class used to simplify text gathering while keeping at as efficient as possible.
    • Field Summary

      • Fields inherited from interface javax.xml.stream.XMLStreamConstants

        ATTRIBUTE, CDATA, CHARACTERS, COMMENT, DTD, END_DOCUMENT, END_ELEMENT, ENTITY_DECLARATION, ENTITY_REFERENCE, NAMESPACE, NOTATION_DECLARATION, PROCESSING_INSTRUCTION, SPACE, START_DOCUMENT, START_ELEMENT
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private Stax2Util()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      private static boolean _isSpace​(char c)
      Note that it is assumed that any "weird" white space (xml 1.1 LSEP and NEL) have been replaced by canonical alternatives (linefeed for element content, regular space for attributes)
      static java.lang.String eventTypeDesc​(int type)
      Method that converts given standard Stax event type into textual representation.
      static java.lang.String trimSpaces​(java.lang.String lexical)
      Method called to trim leading and/or trailing space that given lexical value has.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • Stax2Util

        private Stax2Util()
    • Method Detail

      • eventTypeDesc

        public static java.lang.String eventTypeDesc​(int type)
        Method that converts given standard Stax event type into textual representation.
      • trimSpaces

        public static java.lang.String trimSpaces​(java.lang.String lexical)
        Method called to trim leading and/or trailing space that given lexical value has.
        Returns:
        Trimmed value if lexical had at least one non-space character; null otherwise
      • _isSpace

        private static final boolean _isSpace​(char c)

        Note that it is assumed that any "weird" white space (xml 1.1 LSEP and NEL) have been replaced by canonical alternatives (linefeed for element content, regular space for attributes)