Skip to main content

Class: abstract BaseDocumentStore

Constructors

new BaseDocumentStore()

new BaseDocumentStore(): BaseDocumentStore

Returns

BaseDocumentStore

Properties

serializer

serializer: Serializer<any>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:23

Methods

addDocuments()

abstract addDocuments(docs, allowUpdate): Promise<void>

Parameters

docs: BaseNode<Metadata>[]

allowUpdate: boolean

Returns

Promise<void>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:26


deleteDocument()

abstract deleteDocument(docId, raiseError): Promise<void>

Parameters

docId: string

raiseError: boolean

Returns

Promise<void>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:28


deleteRefDoc()

abstract deleteRefDoc(refDocId, raiseError): Promise<void>

Parameters

refDocId: string

raiseError: boolean

Returns

Promise<void>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:35


docs()

abstract docs(): Promise<Record<string, BaseNode<Metadata>>>

Returns

Promise<Record<string, BaseNode<Metadata>>>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:25


documentExists()

abstract documentExists(docId): Promise<boolean>

Parameters

docId: string

Returns

Promise<boolean>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:29


getAllDocumentHashes()

abstract getAllDocumentHashes(): Promise<Record<string, string>>

Returns

Promise<Record<string, string>>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:32


getAllRefDocInfo()

abstract getAllRefDocInfo(): Promise<undefined | Record<string, RefDocInfo>>

Returns

Promise<undefined | Record<string, RefDocInfo>>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:33


getDocument()

abstract getDocument(docId, raiseError): Promise<undefined | BaseNode<Metadata>>

Parameters

docId: string

raiseError: boolean

Returns

Promise<undefined | BaseNode<Metadata>>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:27


getDocumentHash()

abstract getDocumentHash(docId): Promise<undefined | string>

Parameters

docId: string

Returns

Promise<undefined | string>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:31


getNode()

getNode(nodeId, raiseError?): Promise<BaseNode<Metadata>>

Parameters

nodeId: string

raiseError?: boolean

Returns

Promise<BaseNode<Metadata>>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:37


getNodeDict()

getNodeDict(nodeIdDict): Promise<Record<number, BaseNode<Metadata>>>

Parameters

nodeIdDict

Returns

Promise<Record<number, BaseNode<Metadata>>>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:38


getNodes()

getNodes(nodeIds, raiseError?): Promise<BaseNode<Metadata>[]>

Parameters

nodeIds: string[]

raiseError?: boolean

Returns

Promise<BaseNode<Metadata>[]>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:36


getRefDocInfo()

abstract getRefDocInfo(refDocId): Promise<undefined | RefDocInfo>

Parameters

refDocId: string

Returns

Promise<undefined | RefDocInfo>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:34


persist()

persist(persistPath?): void

Parameters

persistPath?: string

Returns

void

Defined in

packages/core/storage/doc-store/dist/index.d.ts:24


setDocumentHash()

abstract setDocumentHash(docId, docHash): Promise<void>

Parameters

docId: string

docHash: string

Returns

Promise<void>

Defined in

packages/core/storage/doc-store/dist/index.d.ts:30