Enum VersionExtractor

java.lang.Object
java.lang.Enum<VersionExtractor>
org.apache.hadoop.ozone.om.request.validation.VersionExtractor
All Implemented Interfaces:
Serializable, Comparable<VersionExtractor>

public enum VersionExtractor extends Enum<VersionExtractor>
Class to extract version out of OM request.
  • Enum Constant Details

    • LAYOUT_VERSION_EXTRACTOR

      public static final VersionExtractor LAYOUT_VERSION_EXTRACTOR
      Extracts current metadata layout version.
    • CLIENT_VERSION_EXTRACTOR

      public static final VersionExtractor CLIENT_VERSION_EXTRACTOR
      Extracts client version from the OMRequests.
  • Method Details

    • values

      public static VersionExtractor[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static VersionExtractor 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
    • extractVersion

      public abstract org.apache.hadoop.ozone.Versioned extractVersion(org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMRequest req, ValidationContext ctx)
    • getValidatorClass

      public abstract Class<? extends Annotation> getValidatorClass()