Builder

class Builder(storage: Storage, secureAreaRepository: SecureAreaRepository)

A builder for DocumentStore.

Parameters

storage

the Storage to use for storing/retrieving documents.

secureAreaRepository

the repository of configured SecureArea that can be used.

Constructors

Link copied to clipboard
constructor(storage: Storage, secureAreaRepository: SecureAreaRepository)

Functions

Link copied to clipboard
fun addCredentialImplementation(credentialType: String, createCredentialFunction: suspend (Document) -> Credential): DocumentStore.Builder

Add a new Credential implementation to document store.

Link copied to clipboard
Link copied to clipboard
fun setDocumentMetadataFactory(factory: suspend (documentId: String, data: ByteString?, saveFn: suspend (data: ByteString) -> Unit) -> AbstractDocumentMetadata): DocumentStore.Builder

Sets the factory function for creating AbstractDocumentMetadata instances.

Link copied to clipboard

Sets the StorageTableSpec to use for the storage of the documents