import { LiveValidationError } from "../models"; import { LowerHttpMethods, Operation, SwaggerSpec } from "../swagger/swaggerTypes"; import { RegExpWithKeys } from "../transform/pathRegexTransformer"; import { LiveValidatorLoggingLevels, LiveValidatorLoggingTypes } from "./liveValidator"; import { ValidationRequest } from "./operationValidator"; export interface OperationMatch { operation: Operation; pathRegex: RegExpWithKeys; pathMatch: RegExpExecArray; } interface PotentialOperationsResult { readonly matches: OperationMatch[]; readonly resourceProvider: string; readonly apiVersion: string; readonly reason?: LiveValidationError; } type ApiVersion = Map; type Provider = Map; export declare class OperationSearcher { private logging; readonly cache: Map; constructor(logging: (message: string, level?: LiveValidatorLoggingLevels, loggingType?: LiveValidatorLoggingTypes, operationName?: string, durationInMilliseconds?: number, validationRequest?: ValidationRequest) => void); addSpecToCache(spec: SwaggerSpec): void; /** * Gets the swagger operation based on the HTTP url and method */ search(info: ValidationRequest): { operationMatch: OperationMatch; apiVersion: string; }; /** * Gets list of potential operations objects for given url and method. * * @param requestInfo The parsed request info for which to find potential operations. * * @returns Potential operation result object. */ getPotentialOperations(requestInfo: ValidationRequest): PotentialOperationsResult; } export {}; //# sourceMappingURL=operationSearcher.d.ts.map