Options.byDefault constructor

Options.byDefault({
  1. Comparator? comparator,
  2. FilterPolicy? filterPolicy,
  3. bool createIfMissing = false,
  4. bool errorIfExists = false,
  5. bool paranoidChecks = false,
  6. Env? env,
  7. int writeBufferSize = 4 * 1024 * 1024,
  8. int maxOpenFiles = 1000,
  9. Cache? blockCache,
  10. int blockSize = 4 * 1024,
  11. int blockRestartInterval = 16,
  12. int maxFileSize = 2 * 1024 * 1024,
  13. CompressionType compressionType = CompressionType.snappy,
})

Create an Options object with default values for all fields.

Implementation

factory Options.byDefault({
  Comparator? comparator,
  FilterPolicy? filterPolicy,
  bool createIfMissing = false,
  bool errorIfExists = false,
  bool paranoidChecks = false,
  Env? env,
  int writeBufferSize = 4 * 1024 * 1024,
  int maxOpenFiles = 1000,
  Cache? blockCache,
  int blockSize = 4 * 1024,
  int blockRestartInterval = 16,
  int maxFileSize = 2 * 1024 * 1024,
  CompressionType compressionType = CompressionType.snappy,
}) =>
    _Options(
      Lib.levelDB,
      comparator: comparator,
      filterPolicy: filterPolicy,
      createIfMissing: createIfMissing,
      errorIfExists: errorIfExists,
      paranoidChecks: paranoidChecks,
      env: env,
      writeBufferSize: writeBufferSize,
      maxOpenFiles: maxOpenFiles,
      blockCache: blockCache,
      blockSize: blockSize,
      blockRestartInterval: blockRestartInterval,
      maxFileSize: maxFileSize,
      compressionType: compressionType,
    );