A Database with a primarily asynchronous API.
- Implemented types
Properties
- config → DatabaseConfiguration
-
The configuration which was used to open this database.
no setterinherited
-
defaultCollection
→ Future<
AsyncCollection> -
The default Collection of this database.
no setteroverride
-
defaultScope
→ Future<
AsyncScope> -
The default Scope of this database.
no setteroverride
- hashCode → int
-
The hash code for this object.
no setterinherited
- isClosed → bool
-
Whether this resource has been closed.
no setterinherited
- name → String
-
The name of this database.
no setterinherited
- path → String?
-
The path to this database.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
scopes
→ Future<
List< AsyncScope> > -
The Scopes of this database.
no setteroverride
Methods
-
changeEncryptionKey(
EncryptionKey? newKey) → Future< void> -
Encrypts or decrypts a Database, or changes its EncryptionKey.
override
-
close(
) → Future< void> -
Closes this database.
inherited
-
collection(
String name, [String scope = Scope.defaultName]) → Future< AsyncCollection?> -
Returns the Collection with the given
namein the givenscope.override -
collections(
[String scope = Scope.defaultName]) → Future< List< AsyncCollection> > -
Returns all the Collections in the given
scope.override -
createCollection(
String name, [String scope = Scope.defaultName]) → Future< AsyncCollection> -
Creates a Collection with the given
namein the specifiedscope.override -
createQuery(
String query, {bool json = false}) → Future< AsyncQuery> -
Creates a Query from a query string.
override
-
delete(
) → Future< void> -
Closes and deletes this database.
inherited
-
deleteCollection(
String name, [String scope = Scope.defaultName]) → Future< void> -
Deletes the Collection with the given
namein the givenscope.override -
getBlob(
Map< String, Object?> properties) → Future<Blob?> -
Gets a Blob using its metadata.
override
-
inBatch(
FutureOr< void> fn()) → Future<void> -
Runs a group of database operations in a batch.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
performMaintenance(
MaintenanceType type) → Future< void> -
Performs database maintenance.
override
-
saveBlob(
Blob blob) → Future< void> -
Saves a Blob directly into this database without associating it with any
Documents.
override
-
scope(
String name) → Future< AsyncScope?> -
Returns the Scope with the given
name.override -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
copy(
{required String from, required String name, DatabaseConfiguration? config}) → Future< void> -
Copies a canned database
fromthe given path to a new database with the givennameandconfig.override -
exists(
String name, {String? directory}) → Future< bool> -
Checks whether a database of the given
nameexists in the givendirectoryor not.override -
open(
String name, [DatabaseConfiguration? config]) → Future< AsyncDatabase> -
Opens a Couchbase Lite database with the given
nameandconfig, which executes in a separate worker isolate. -
remove(
String name, {String? directory}) → Future< void> -
Deletes a database of the given
namein the givendirectory.override