Storage_2 Interface
Packages > @anticrm/core > Storage_2
Signature:
export interface Storage
Properties #
Property | Type | Description |
---|---|---|
find | ||
findOne | ||
remove | (ctx: TxContext, _class: Ref<Class<Doc>>, _id: Ref<Doc>) => Promise |
|
store | (ctx: TxContext, doc: Doc) => Promise |
|
update | (ctx: TxContext, _class: Ref<Class<Doc>>, _id: Ref<Doc>, operations: TxOperation[]) => Promise |
Events #
find #
Signature:
find: <T extends Doc>(_class: Ref<Class<T>>, query: DocumentQuery<T>, options?: FindOptions<T>) => Promise<T[]>;
findOne #
Signature:
findOne: <T extends Doc>(_class: Ref<Class<T>>, query: DocumentQuery<T>) => Promise<T | undefined>;
remove #
Signature:
remove: (ctx: TxContext, _class: Ref<Class<Doc>>, _id: Ref<Doc>) => Promise<void>;
store #
Signature:
store: (ctx: TxContext, doc: Doc) => Promise<void>;
update #
Signature:
update: (ctx: TxContext, _class: Ref<Class<Doc>>, _id: Ref<Doc>, operations: TxOperation[]) => Promise<void>;