import { type TypeAttributeKind, type TypeAttributes } from "../attributes/TypeAttributes"; import { Graph } from "../Graph"; import { GraphRewriteBuilder } from "../GraphRewriting"; import type { Type } from "./Type"; import type { TypeBuilder } from "./TypeBuilder"; import { type StringTypeMapping } from "./TypeBuilderUtils"; import { type TypeRef } from "./TypeRef"; import { type SeparatedNamedTypes } from "./TypeUtils"; export declare class TypeAttributeStore { private readonly _typeGraph; private _values; private readonly _topLevelValues; constructor(_typeGraph: TypeGraph, _values: Array); private getTypeIndex; attributesForType(t: Type): TypeAttributes; attributesForTopLevel(name: string): TypeAttributes; setInMap(attributes: TypeAttributes, kind: TypeAttributeKind, value: T): TypeAttributes; set(kind: TypeAttributeKind, t: Type, value: T): void; setForTopLevel(kind: TypeAttributeKind, topLevelName: string, value: T): void; tryGetInMap(attributes: TypeAttributes, kind: TypeAttributeKind): T | undefined; tryGet(kind: TypeAttributeKind, t: Type): T | undefined; tryGetForTopLevel(kind: TypeAttributeKind, topLevelName: string): T | undefined; } export declare class TypeAttributeStoreView { private readonly _attributeStore; private readonly _definition; constructor(_attributeStore: TypeAttributeStore, _definition: TypeAttributeKind); set(t: Type, value: T): void; setForTopLevel(name: string, value: T): void; tryGet(t: Type): T | undefined; get(t: Type): T; tryGetForTopLevel(name: string): T | undefined; getForTopLevel(name: string): T; } export declare class TypeGraph { readonly serial: number; private readonly _haveProvenanceAttributes; private _typeBuilder?; private _attributeStore; private _topLevels; private _types?; private _parents; private _printOnRewrite; constructor(typeBuilder: TypeBuilder, serial: number, _haveProvenanceAttributes: boolean); private get isFrozen(); get attributeStore(): TypeAttributeStore; freeze(topLevels: ReadonlyMap, types: Type[], typeAttributes: Array): void; get topLevels(): ReadonlyMap; typeAtIndex(index: number): Type; atIndex(index: number): [Type, TypeAttributes]; private filterTypes; allNamedTypes(): ReadonlySet; allNamedTypesSeparated(): SeparatedNamedTypes; private allProvenance; setPrintOnRewrite(): void; private checkLostTypeAttributes; private printRewrite; rewrite(title: string, stringTypeMapping: StringTypeMapping, alphabetizeProperties: boolean, replacementGroups: T[][], debugPrintReconstitution: boolean, replacer: (typesToReplace: ReadonlySet, builder: GraphRewriteBuilder, forwardingRef: TypeRef) => TypeRef, force?: boolean): TypeGraph; remap(title: string, stringTypeMapping: StringTypeMapping, alphabetizeProperties: boolean, map: ReadonlyMap, debugPrintRemapping: boolean, force?: boolean): TypeGraph; garbageCollect(alphabetizeProperties: boolean, debugPrintReconstitution: boolean): TypeGraph; rewriteFixedPoint(alphabetizeProperties: boolean, debugPrintReconstitution: boolean): TypeGraph; allTypesUnordered(): ReadonlySet; makeGraph(invertDirection: boolean, childrenOfType: (t: Type) => ReadonlySet): Graph; getParentsOfType(t: Type): Set; printGraph(): void; }