Enum Class OpenOption

java.lang.Object
java.lang.Enum<OpenOption>
org.cojen.tupl.io.OpenOption
All Implemented Interfaces:
Serializable, Comparable<OpenOption>, Constable

public enum OpenOption extends Enum<OpenOption>
Open options for FilePageArray.
  • Enum Constant Details

    • READ_ONLY

      public static final OpenOption READ_ONLY
      Open file in read-only mode.
    • CREATE

      public static final OpenOption CREATE
      Create the file if it doesn't already exist.
    • MAPPED

      public static final OpenOption MAPPED
      Map the file into main memory.
    • SYNC_IO

      public static final OpenOption SYNC_IO
      All file I/O should be durable.
    • DIRECT_IO

      public static final OpenOption DIRECT_IO
      All file I/O should be durable and bypass the file system cache, if possible.
    • NON_DURABLE

      public static final OpenOption NON_DURABLE
      File contents don't persist after an OS crash or power failure.
    • RANDOM_ACCESS

      public static final OpenOption RANDOM_ACCESS
      Indicate that file will be accessed in random order.
    • READAHEAD

      public static final OpenOption READAHEAD
      Optional hint to perform readahead on the file.
    • CLOSE_DONTNEED

      public static final OpenOption CLOSE_DONTNEED
      Optional hint to apply at file close indicating that the file data will not be accessed in the near future.
  • Method Details

    • values

      public static OpenOption[] 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 OpenOption 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