import { ICancellablePromise, TAbortStrategy } from '@lifaon/observables'; import { IHTTPRoute } from './interfaces'; import { IRouteExecCallbackOptions, IRouteOptions, IRouteResolveCallbackOptions } from '../../core/route/types'; import { IRoute } from '../../core/route/interfaces'; import { IResolvableTreeResolveCallbackNormalizedOptions } from '../../core/resolvable-tree/functions'; /** TYPES */ export declare type HTTPMethod = 'GET' | 'HEAD' | 'POST' | 'PUT' | 'DELETE' | 'OPTIONS'; export interface IHTTPRouteResolveCallbackOptions extends IRouteResolveCallbackOptions { method: HTTPMethod; } export interface IHTTPRouteResolveIncomingCallbackOptions extends Pick, 'path' | 'method'>, IResolvableTreeResolveCallbackNormalizedOptions { } export declare type IHTTPRouteResolveCallbackNormalizedOptions = IHTTPRouteResolveIncomingCallbackOptions; export declare type THTTPRouteResolveCallback = (this: IHTTPRoute, options: IHTTPRouteResolveCallbackNormalizedOptions) => ICancellablePromise; export interface IHTTPRouteExecCallbackOptions extends IRouteExecCallbackOptions { } export declare type THTTPRouteExecCallback = (this: IRoute, options: IHTTPRouteExecCallbackOptions) => ICancellablePromise; export interface IHTTPRouteOptions extends Omit { children?: Iterable; resolve?: THTTPRouteResolveCallback; exec?: THTTPRouteExecCallback; methods?: Iterable; }