import { EntityPropertyTypes } from 'mel-common'; import { EntityLiteral } from '../../core/types'; import { FieldTriggerResult, FieldValidationResult } from './types'; /** * This class is the baseclass of all concrete EntityTriggers * It contains the triggerData where the fields are validated and triggered and two methods * 1. runTrigger(..) is called from the entityUi, when a fieldvalue changes * 2. trigger(..) is called from inside a trigger to trigger other values * The difference is only the initializion of the triggerdata and the returnvalue * */ export declare class FieldTriggers { constructor(entityName: string); private triggerData; protected trigger(fieldName: string, value: any): void; validate(fieldName: string, value?: EntityPropertyTypes): FieldValidationResult; runTrigger(fieldName: string, value: EntityPropertyTypes, sourceEntity: EntityLiteral): Promise; }