/** * An array of arguments + the next function */ export declare type MiddlewareArgs = any[]; /** * The middleware actual function */ export declare type MiddlewareFn = (...params: MiddlewareArgs) => Promise; /** * Executor job is to execute one middleware function at a * time and pass arguments to it */ export declare type Executor = (fn: any, params: MiddlewareArgs) => Promise; /** * Args received by the final handler */ export declare type FinalHandlerArgs = any[]; /** * Final handler is called when the entire chain executes * completely */ export declare type FinalHandler = (...params: FinalHandlerArgs) => Promise;