import { HookFunction, AjaxType, AjaxInterceptorCreateInstanceOptions } from './type'; import { XhrInterceptor } from './xhr'; import { FetchInterceptor } from './fetch'; declare class AjaxInterceptor { #private; /** * 1.x compatibility field. * Direct access to internal instances is still available in 1.x, * and is planned to become private in 2.x. * Prefer `hook` / `unhook` / `inject` / `uninject`. */ xhrInterceptor: XhrInterceptor; /** * 1.x compatibility field. * Direct access to internal instances is still available in 1.x, * and is planned to become private in 2.x. * Prefer `hook` / `unhook` / `inject` / `uninject`. */ fetchInterceptor: FetchInterceptor; static getInstance(options?: AjaxInterceptorCreateInstanceOptions): AjaxInterceptor; private constructor(); private toggleInject; inject(type?: AjaxType): void; uninject(type?: AjaxType): void; hook(fn: HookFunction, type?: AjaxType): void; unhook(fn?: HookFunction, type?: AjaxType): void; } export default AjaxInterceptor; export { AjaxInterceptor };