import type { FuseResult } from "fuse.js"; import Fuse from "fuse.js"; import jsonToAst from "json-to-ast"; import type { CacheCapabilitiesManager, SchemaService } from "@warp-drive/core/types"; import type { StructuredDataDocument, StructuredDocument, StructuredErrorDocument } from "@warp-drive/core/types/request"; import type { FieldSchema } from "@warp-drive/core/types/schema/fields"; import type { ResourceDataDocument, ResourceDocument, ResourceErrorDocument, ResourceMetaDocument } from "@warp-drive/core/types/spec/document"; export declare function inspectType(obj: unknown): string; export declare function isSimpleObject(obj: unknown): obj is Record; export declare const RELATIONSHIP_FIELD_KINDS: string[]; export type PathLike = Array; interface ErrorReport { path: PathLike; message: string; loc: { start: { line: number; column: number; offset: number; }; end: { line: number; column: number; offset: number; }; }; type: "error" | "warning" | "info"; kind: "key" | "value"; } export declare class Reporter { capabilities: CacheCapabilitiesManager; contextDocument: StructuredDocument; errors: ErrorReport[]; ast: ReturnType; jsonStr: string; strict: { linkage: boolean; unknownType: boolean; unknownAttribute: boolean; unknownRelationship: boolean; }; constructor(capabilities: CacheCapabilitiesManager, doc: StructuredDocument); _typeFilter: Fuse | undefined; searchTypes(type: string): FuseResult[]; _fieldFilters: Map>; searchFields(type: string, field: string): FuseResult[]; get schema(): SchemaService; getLocation(path: PathLike, kind: "key" | "value"): { start: { line: number; column: number; offset: number; }; end: { line: number; column: number; offset: number; }; }; error(path: PathLike, message: string, kind?: "key" | "value"): void; warn(path: PathLike, message: string, kind?: "key" | "value"): void; info(path: PathLike, message: string, kind?: "key" | "value"): void; hasExtension(extensionName: string): boolean; getExtension(extensionName: string): ReporterFn | undefined; report(colorize?: boolean): void; } type ReporterFn = (reporter: Reporter, path: PathLike) => void; export declare function isMetaDocument(doc: StructuredDocument): doc is StructuredDataDocument; export declare function isErrorDocument(doc: StructuredDocument): doc is StructuredErrorDocument; export declare function isPushedDocument(doc: unknown): doc is { content: ResourceDataDocument; }; export declare function logPotentialMatches(matches: FuseResult[], kind: string): string; export declare function getRemoteField(fields: Map, key: string): FieldSchema | undefined; export {};