import { Member, PlatformID } from '@digitaldefiance/ecies-lib'; import { IBrightTrustDocument } from '../interfaces/document/brightTrustDocument'; import { BlockService } from '../services/blockService'; import { MemberCblService } from '../services/member/memberCblService'; import { Document } from './base/document'; export type { IBrightTrustDocument }; /** * A BrightTrustDocument has its data stored in the blockchain and is encrypted with a key that is shared among a trusted brightTrust * of members using Shamir's Secret Sharing and the keys are kept within the BrightTrust. */ export declare class BrightTrustDocument = IBrightTrustDocument> extends Document { constructor(data: Partial); protected static memberService: MemberCblService | undefined; static initialize(blockService: BlockService, memberService: MemberCblService): void; static createFromJson>(json: string): BrightTrustDocument; /** * Save the document, creating CBLs for members as needed */ save(): Promise; /** * Load the document, hydrating members from CBLs */ load(): Promise; /** * Delete the document */ delete(): Promise; /** * Encrypt document data using Shamir's Secret Sharing * @param data The data to encrypt * @param members The members to distribute shares to * @param sharesRequired Optional number of shares required to decrypt (defaults to all members) */ encrypt(data: T, members: Member[], sharesRequired?: number): Promise; /** * Decrypt document data using the provided member keys * @param membersWithKeys Members with loaded private keys * @returns The decrypted data */ decrypt(membersWithKeys: Member[]): Promise; } //# sourceMappingURL=brightTrustDocument.d.ts.map