Enum VersionType

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<VersionType>

    public enum VersionType
    extends java.lang.Enum<VersionType>
    The next logical version type that is generated when creating or checking in a new version of a file.
    Since:
    1.1
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      CUSTOM
      The file version that is created is specified by the user.
      MAJOR
      The file version that is created is the next logical major version.
      MINOR
      The file version that is created is the next logical minor version.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static VersionType valueOf​(java.lang.String name)
      Returns the enum constant of this type with the specified name.
      static VersionType[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      • Methods inherited from class java.lang.Enum

        clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Enum Constant Detail

      • MAJOR

        public static final VersionType MAJOR
        The file version that is created is the next logical major version. This implies incrementing the major version and resetting the minor version to 0.

        Example:
        The current version is 3.27.
        The next major version will be 4.0.

      • MINOR

        public static final VersionType MINOR
        The file version that is created is the next logical minor version. This implies not changing the current major version and incrementing the minor version.

        Example:
        The current version is 3.27.
        The next minor version will be 3.28.

      • CUSTOM

        public static final VersionType CUSTOM
        The file version that is created is specified by the user. The version specified must be logically larger than the current version, if one exists.

        Example:
        The current version is 3.27.
        The next version must be greater than the current version, such as 3.28, or 24.0. 3.2 would be as invalid, since it is less than the current version.

    • Method Detail

      • values

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

        public static VersionType valueOf​(java.lang.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:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null