UNPKG

@cashfarm/plow

Version:

Library for validating input data and parameters

35 lines (34 loc) 1.11 kB
import { IDomainEvent, IAggregateRoot } from './domain'; /** * Plow framework configuration options * * @export * @interface IPlowConfig */ export interface IPlowConfig { /** * The name of your application package * * This is used as default when FQNs don't specify a package */ appPackageName?: string; /** * Options for messaging (Events and Commands) */ messaging: { /** * Which transport to use for sending commands and publishing events * * @type {('rabbitmq' | 'inmemory')} */ transport: 'rabbitmq' | 'inmemory'; }; /** * Whether or not Plow should require an explicit Apply method for each event the Aggregate Root is to handle */ requireApplyForEachEvent: boolean; defaultApplyFn(aggt: IAggregateRoot<any>, event: IDomainEvent): void; } export declare function CopyPropsToUnderscoreProp(aggt: IAggregateRoot<any>, event: IDomainEvent): void; export declare function CopyProps(aggt: IAggregateRoot<any>, event: IDomainEvent): void; export declare const PlowConfig: IPlowConfig;