Enum EXMLVersion

    • Enum Constant Detail

      • XML_10

        public static final EXMLVersion XML_10
        XML 1.0 - this should be the default
      • XML_11

        public static final EXMLVersion XML_11
        XML 1.1
    • Method Detail

      • values

        public static EXMLVersion[] 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 (EXMLVersion c : EXMLVersion.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static EXMLVersion 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
      • getVersion

        @Nonnull
        @Nonempty
        public String getVersion()
        Returns:
        The textual representation of the XML version number.
      • getFromVersionOrNull

        @Nullable
        public static EXMLVersion getFromVersionOrNull​(@Nullable
                                                       String sVersion)
        Find the EXMLVersion object matching the passed version string.
        Parameters:
        sVersion - The version string to search. May be null.
        Returns:
        null if no such EXMLVersion object is present.
      • getFromVersionOrDefault

        @Nullable
        public static EXMLVersion getFromVersionOrDefault​(@Nullable
                                                          String sVersion,
                                                          @Nullable
                                                          EXMLVersion eDefault)
        Find the EXMLVersion object matching the passed version string.
        Parameters:
        sVersion - The version string to search. May be null.
        eDefault - The default version to be returned, if no such enum value is present. May be null.
        Returns:
        The provided default version (which may be null) if no such EXMLVersion object is present.