Interface EventStore<K, V, QueryExt>

An append-only event store.

interface EventStore {
    entries(options?): SyncOrAsyncGenerator<[K, V], K[]>;
    get(key, options?): MaybePromise<undefined | V>;
    getKey(value, options?): MaybePromise<K>;
    getMany(keys, options?): MaybeAsyncIterableIterator<undefined | V>;
    has(key, options?): MaybePromise<boolean>;
    hasMany(keys, options?): MaybeAsyncIterableIterator<boolean>;
    keys(options?): SyncOrAsyncGenerator<K, K[]>;
    put(value, options?): MaybePromise<K>;
    putMany(values, options?): MaybeAsyncIterableIterator<[key: K, error?: Error]>;
    validate(value, options?): MaybePromise<undefined | Error>;
    values(options?): SyncOrAsyncGenerator<V, K[]>;
}

Type Parameters

  • K = ContentId

  • V = unknown

  • QueryExt extends object = NonNullable<unknown>

Hierarchy

Implemented by

Methods

Generated using TypeDoc