import { Export, Extname, File, Import, ResolvedExport, ResolvedFile, ResolvedImport } from "./index-CGJ3tdk-.js";
import { Logger } from "./logger-B-4AXUmB.js";
import { Config, PossiblePromise } from "./PluginManager-BSUDeUfP.js";

//#region src/utils/FunctionParams.d.ts
type FunctionParamsASTWithoutType = {
  name?: string;
  type?: string;
  /**
   * @default true
   */
  required?: boolean;
  /**
   * @default true
   */
  enabled?: boolean;
  default?: string;
};
type FunctionParamsASTWithType = {
  name?: never;
  type: string;
  /**
   * @default true
   */
  required?: boolean;
  /**
   * @default true
   */
  enabled?: boolean;
  default?: string;
};
/**
 * @deprecated
 */
type FunctionParamsAST = FunctionParamsASTWithoutType | FunctionParamsASTWithType;
/**
 * @deprecated
 */
declare class FunctionParams {
  #private;
  constructor();
  get items(): FunctionParamsAST[];
  add(item: FunctionParamsAST | Array<FunctionParamsAST | FunctionParamsAST[] | undefined> | undefined): FunctionParams;
  static toObject(items: FunctionParamsAST[]): FunctionParamsAST;
  static toString(items: (FunctionParamsAST | FunctionParamsAST[])[]): string;
  toObject(): FunctionParamsAST;
  toString(): string;
}
//#endregion
//#region src/utils/promise.d.ts
declare function isPromise<T>(result: PossiblePromise<T>): result is Promise<T>;
declare function isPromiseFulfilledResult<T = unknown>(result: PromiseSettledResult<unknown>): result is PromiseFulfilledResult<T>;
declare function isPromiseRejectedResult<T>(result: PromiseSettledResult<unknown>): result is Omit<PromiseRejectedResult, 'reason'> & {
  reason: T;
};
//#endregion
//#region src/utils/renderTemplate.d.ts
declare function renderTemplate<TData extends Record<string, unknown> = Record<string, unknown>>(template: string, data?: TData | undefined): string;
//#endregion
//#region src/utils/timeout.d.ts
declare function timeout(ms: number): Promise<unknown>;
//#endregion
//#region src/utils/uniqueName.d.ts
declare function getUniqueName(originalName: string, data: Record<string, number>): string;
declare function setUniqueName(originalName: string, data: Record<string, number>): string;
//#endregion
//#region src/utils/URLPath.d.ts
type URLObject = {
  url: string;
  params?: Record<string, string>;
};
type ObjectOptions = {
  type?: 'path' | 'template';
  replacer?: (pathParam: string) => string;
  stringify?: boolean;
};
type Options = {
  casing?: 'camelcase';
};
declare class URLPath {
  #private;
  path: string;
  constructor(path: string, options?: Options);
  /**
   * Convert Swagger path to URLPath(syntax of Express)
   * @example /pet/{petId} => /pet/:petId
   */
  get URL(): string;
  get isURL(): boolean;
  /**
   * Convert Swagger path to template literals/ template strings(camelcase)
   * @example /pet/{petId} => `/pet/${petId}`
   * @example /account/monetary-accountID => `/account/${monetaryAccountId}`
   * @example /account/userID => `/account/${userId}`
   */
  get template(): string;
  get object(): URLObject | string;
  get params(): Record<string, string> | undefined;
  toObject({
    type,
    replacer,
    stringify
  }?: ObjectOptions): URLObject | string;
  /**
   * Convert Swagger path to template literals/ template strings(camelcase)
   * @example /pet/{petId} => `/pet/${petId}`
   * @example /account/monetary-accountID => `/account/${monetaryAccountId}`
   * @example /account/userID => `/account/${userId}`
   */
  toTemplateString({
    prefix,
    replacer
  }?: {
    prefix?: string;
    replacer?: (pathParam: string) => string;
  }): string;
  getParams(replacer?: (pathParam: string) => string): Record<string, string> | undefined;
  /**
   * Convert Swagger path to URLPath(syntax of Express)
   * @example /pet/{petId} => /pet/:petId
   */
  toURLPath(): string;
}
//#endregion
//#region src/utils/parser.d.ts
/**
 * Generate a default banner for files created by Kubb
 * @returns A string with the default banner
 */
declare function getDefaultBanner({
  title,
  description,
  version,
  config
}: {
  title?: string;
  description?: string;
  version?: string;
  config: Config;
}): string;
/**
 * Helper to create a file with name and id set
 */
declare function createFile<TMeta extends object = object>(file: File<TMeta>): ResolvedFile<TMeta>;
/**
 * Helper to create a fileImport with extname set
 */
declare function createFileImport(imp: Import): ResolvedImport;
/**
 * Helper to create a fileExport with extname set
 */
declare function createFileExport(exp: Export): ResolvedExport;
type ParserModule<TMeta extends object = object> = {
  /**
   * Convert a file to string
   */
  print: (file: ResolvedFile<TMeta>, options: PrintOptions) => Promise<string>;
};
declare function createFileParser<TMeta extends object = object>(parser: ParserModule<TMeta>): ParserModule<TMeta>;
type PrintOptions = {
  extname?: Extname;
  logger?: Logger;
};
declare function getFileParser<TMeta extends object = object>(extname: Extname | undefined): Promise<ParserModule<TMeta>>;
//#endregion
//#region src/utils/Cache.d.ts
declare class Cache<T> {
  #private;
  get(key: string): Promise<T | null>;
  set(key: string, value: T): Promise<void>;
  delete(key: string): Promise<void>;
  clear(): Promise<void>;
  keys(): Promise<string[]>;
  values(): Promise<T[]>;
  flush(): Promise<void>;
}
//#endregion
export { Cache, FunctionParams, type FunctionParamsAST, type ParserModule, type URLObject, URLPath, createFile, createFileExport, createFileImport, createFileParser, getDefaultBanner, getFileParser, getUniqueName, isPromise, isPromiseFulfilledResult, isPromiseRejectedResult, renderTemplate, setUniqueName, timeout };
//# sourceMappingURL=index-BhFFCWR1.d.ts.map