/** @packageDocumentation * @module Core */ import { IModelDb } from "@itwin/core-backend"; import { Id64String } from "@itwin/core-bentley"; import { Diagnostics, DiagnosticsOptions, InstanceKey } from "@itwin/presentation-common"; /** @internal */ export declare function getLocalizedStringEN(key: string): string; /** @internal */ export declare function getElementKey(imodel: IModelDb, id: Id64String): InstanceKey | undefined; /** @internal */ export declare function normalizeVersion(version?: string): string; /** * A function that received request diagnostics and, optionally, request context. * @public */ export type BackendDiagnosticsHandler = (logs: Diagnostics, requestContext?: TContext) => void; /** * Data structure for backend diagnostics options. * @public */ export interface BackendDiagnosticsOptions extends DiagnosticsOptions { /** * An optional function to supply request context that'll be passed to [[handler]] when * it's called after the request is fulfilled. */ requestContextSupplier?: () => TContext; /** * Request diagnostics handler function that is called after the request is fulfilled. The handler * receives request diagnostics as the first argument and, optionally, request context as the * second (see [[requestContextSupplier]]). */ handler: BackendDiagnosticsHandler; } /** * Data structure which contains backend diagnostics options. * @public */ export interface BackendDiagnosticsAttribute { /** * Backend diagnostics options. * @public */ diagnostics?: BackendDiagnosticsOptions; } /** @internal */ export declare function combineDiagnosticsOptions(...options: Array): DiagnosticsOptions | undefined; /** @internal */ export declare function reportDiagnostics(diagnostics: Diagnostics, options: BackendDiagnosticsOptions, context?: TContext): void; //# sourceMappingURL=Utils.d.ts.map