import * as Joi from 'joi'; import { IContext } from '../interfaces'; import { ActionSnapshot } from './ActionSnapshot'; import { IDelegatedParameters } from '../interfaces/IDelegatedParameters'; export declare abstract class ActionProcessor { protected options: any; protected context: IContext; protected snapshot: ActionSnapshot; protected parameters: IDelegatedParameters; constructor(options: any, context: IContext, snapshot: ActionSnapshot, parameters: IDelegatedParameters); /** * Validate options before processing. * Should throw exception on error. */ validate(): Promise; /** * Get Joi schema to validate options with * Return null if no validation should be applied, though it is not recommended. */ protected getValidationSchema(): Joi.Schema | null; /** * Check if action should be actually executed */ isShouldExecute(): Promise; /** * Execute action */ abstract execute(): Promise; }