Enum Class OrcFile.WriterVersion

java.lang.Object
java.lang.Enum<OrcFile.WriterVersion>
org.apache.orc.OrcFile.WriterVersion
All Implemented Interfaces:
Serializable, Comparable<OrcFile.WriterVersion>, Constable
Enclosing class:
OrcFile

public static enum OrcFile.WriterVersion extends Enum<OrcFile.WriterVersion>
Records the version of the writer in terms of which bugs have been fixed. When you fix bugs in the writer (or make substantial changes) that don't change the file format, add a new version here instead of Version. The ids are assigned sequentially from 6 per a WriterImplementation so that readers that predate ORC-202 treat the other writers correctly.
  • Enum Constant Details

  • Method Details

    • values

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

      public static OrcFile.WriterVersion valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified name
      NullPointerException - if the argument is null
    • getWriterImplementation

      public OrcFile.WriterImplementation getWriterImplementation()
    • getId

      public int getId()
    • from

      public static OrcFile.WriterVersion from(OrcFile.WriterImplementation writer, int val)
      Convert the integer from OrcProto.PostScript.writerVersion to the enumeration with unknown versions being mapped to FUTURE.
      Parameters:
      writer - the writer implementation
      val - the serialized writer version
      Returns:
      the corresponding enumeration value
    • includes

      public boolean includes(OrcFile.WriterVersion fix)
      Does this file include the given fix or come from a different writer?
      Parameters:
      fix - the required fix
      Returns:
      true if the required fix is present