Package cdc.util.xml

Enum XmlWriterContext.Type

    • Enum Constant Detail

      • IN_OPEN_STREAM

        public static final XmlWriterContext.Type IN_OPEN_STREAM
        Initial state, before calling beginDocument.

        Stream is empty.

      • IN_OPEN_DOC

        public static final XmlWriterContext.Type IN_OPEN_DOC
        After calling beginDocument

        Stream contains the xml declaration.

      • IN_TAG

        public static final XmlWriterContext.Type IN_TAG
        After calling beginElement.

        One can add attributes to that element, or content (text, comments, ...) to it.

      • IN_SIMPLE_CONTENT

        public static final XmlWriterContext.Type IN_SIMPLE_CONTENT
        Replaces IN_TAG and indicates that the element content is simple.
      • IN_MIXED_CONTENT

        public static final XmlWriterContext.Type IN_MIXED_CONTENT
        Replaces IN_TAG and indicates that the element content is complex.
      • IN_CLOSED_DOC

        public static final XmlWriterContext.Type IN_CLOSED_DOC
        After closing of the root element.

        We can not add more elements.

      • IN_CLOSED_STREAM

        public static final XmlWriterContext.Type IN_CLOSED_STREAM
        After calling endDocument.

        One can not do anything after that, except closing the stream.

    • Method Detail

      • values

        public static XmlWriterContext.Type[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (XmlWriterContext.Type c : XmlWriterContext.Type.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static XmlWriterContext.Type valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null