newObjectboxLocalVaultStore function

Future<ObjectboxVaultStore> newObjectboxLocalVaultStore({
  1. String? path,
  2. StoreCodec? codec,
  3. int? maxDBSizeInKB,
  4. int? fileMode,
  5. int? maxReaders,
  6. bool? queriesCaseSensitiveDefault,
})

Creates a new ObjectboxVaultStore

  • path: The base storage location for this store
  • codec: The StoreCodec used to convert to/from a Map<String, dynamic>` representation to a binary representation
  • maxDBSizeInKB: The max DB size
  • fileMode: The file mode
  • maxReaders: The number of maximum readers
  • queriesCaseSensitiveDefault: If the queries are case sensitive, the default is true

Implementation

Future<ObjectboxVaultStore> newObjectboxLocalVaultStore(
    {String? path,
    StoreCodec? codec,
    int? maxDBSizeInKB,
    int? fileMode,
    int? maxReaders,
    bool? queriesCaseSensitiveDefault}) {
  return ObjectboxAdapter.build(path ?? Directory.systemTemp.path,
          maxDBSizeInKB: maxDBSizeInKB,
          fileMode: fileMode,
          maxReaders: maxReaders,
          queriesCaseSensitiveDefault: queriesCaseSensitiveDefault)
      .then((adapter) => ObjectboxVaultStore(adapter, codec: codec));
}