org.apache.olingo.commons.api.edm.constants

## Enum ODataServiceVersion

- java.lang.Object
- - java.lang.Enum<ODataServiceVersion>
  - - org.apache.olingo.commons.api.edm.constants.ODataServiceVersion

- All Implemented Interfaces:
    Serializable, Comparable<ODataServiceVersion>

      public enum ODataServiceVersion
      extends Enum<ODataServiceVersion>

  This class is a container for the supported ODataServiceVersions.

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant and Description
    `V10` OData Version 1.0
    `V20` OData Version 2.0
    `V30` OData Version 3.0
    `V40` OData Version 4.0
    `V401` OData Version 4.01

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static boolean` | `isBiggerThan(String firstValue, String secondValue)` Check if `firstValue` is bigger then `secondValue`
    `static boolean` | `isValidMaxODataVersion(String value)`
    `static boolean` | `isValidODataVersion(String value)`
    `String` | `toString()`
    `static boolean` | `validateDataServiceVersion(String version)` Validates format and range of a data service version string.
    `static ODataServiceVersion` | `valueOf(String name)` Returns the enum constant of this type with the specified name.
    `static ODataServiceVersion[]` | `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, valueOf`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Enum Constant Detail

    - #### V10

          public static final ODataServiceVersion V10

      OData Version 1.0

    - #### V20

          public static final ODataServiceVersion V20

      OData Version 2.0

    - #### V30

          public static final ODataServiceVersion V30

      OData Version 3.0

    - #### V40

          public static final ODataServiceVersion V40

      OData Version 4.0

    - #### V401

          public static final ODataServiceVersion V401

      OData Version 4.01

  - ### Method Detail

    - #### values

          public static ODataServiceVersion[] 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 (ODataServiceVersion c : ODataServiceVersion.values())
              System.out.println(c);

      Returns:
        an array containing the constants of this enum type, in the order they are declared

    - #### valueOf

          public static ODataServiceVersion 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

    - #### validateDataServiceVersion

          public static boolean validateDataServiceVersion(String version)

      Validates format and range of a data service version string.
      Parameters:
        `version` - version string
      Returns:
        `true` for a valid version

    - #### isBiggerThan

          public static boolean isBiggerThan(String firstValue,
                                             String secondValue)

      Check if `firstValue` is bigger then `secondValue`
      Parameters:
        `firstValue` - first value which is compared
        `secondValue` - second value which is compared
      Returns:
        `true` if firstValue is bigger than secondValue

    - #### isValidODataVersion

          public static boolean isValidODataVersion(String value)

    - #### isValidMaxODataVersion

          public static boolean isValidMaxODataVersion(String value)

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Enum<ODataServiceVersion>`

Copyright © 2013–2022 The Apache Software Foundation. All rights reserved.