@fabric-es/fabric-cqrs
Version:
Hyperledger Fabric middleware for event sourcing and cqrs pattern
18 lines (17 loc) • 530 B
TypeScript
import { Wallet } from 'fabric-network';
import { Store } from 'redux';
import type { Logger } from 'winston';
import { SaveFcn, Reducer } from '../types';
export declare const commandGetById: <TEntity, TEvent>(entityName: string, reducer: Reducer, isPrivateData: boolean, option: {
channelName: string;
logger: Logger;
connectionProfile: string;
wallet: Wallet;
store: Store;
}) => (option: {
enrollmentId: string;
id: string;
}) => Promise<{
currentState: TEntity;
save: SaveFcn<TEvent>;
}>;