import { BaseTdObject, Composer as BaseComposer, Middleware, MiddlewareFn, NextFn } from '../types'; declare function compose(middlewares: Middleware[]): MiddlewareFn; declare function branch(predicate: unknown, trueMiddleware: Middleware, falseMiddleware: Middleware): MiddlewareFn; declare function optional(predicate: unknown, ...fns: Middleware[]): MiddlewareFn; declare function mount(predicateType: string | string[], ...fns: Middleware[]): Middleware; declare function fork(middleware: Middleware): Middleware; declare function filter(predicate: unknown): Middleware; declare class Composer implements BaseComposer { static compose: typeof compose; static fork: typeof fork; static filter: typeof filter; static branch: typeof branch; static mount: typeof mount; static optional: typeof optional; static noop: NextFn; protected handler: MiddlewareFn; constructor(...fns: Middleware[]); middleware(): MiddlewareFn; on(predicateTypes: string | string[], ...fns: Middleware[]): void; use(...fns: Middleware[]): void; } export { Composer };