import type { HsonNode } from "../../core/types.js"; import type { HsonSchema } from "../transform/transform.types.js"; import type { LiveMapAnyOp, LiveMapGraphOp, LiveMapRootMode, HostedLiveMapLibrariesSnapshot, LiveMapLibrariesSnapshot } from "../../types/livemap.types.js"; import type { LiveMapProjectedGraphEnsureQuidOp } from "./livemap.identity.types.js"; import { type LiveMapProjectedDataOp } from "./livemap.transport.js"; import type { LiveMapLibraryIdentity } from "./livemap.library.js"; export declare const HOSTED_REGISTRY_FORMAT: "hson-hosted-registry"; export declare const HOSTED_COMMIT_FORMAT: "hson-hosted-commit"; export declare const LIVEMAP_LIBRARIES_SNAPSHOT_FORMAT: "hson-livemap-libraries-snapshot"; export declare const HOSTED_GRAPH_OP_FORMAT: "hson-hosted-graph-op"; export declare const HOSTED_ROOT_FORMAT: "hson-exact-value"; export declare const HOSTED_MAX_LIBRARIES = 1024; export declare const HOSTED_MAX_LIBRARY_NAME_BYTES = 1024; export declare const HOSTED_MAX_OPERATIONS = 100000; export declare const HOSTED_MAX_COMMIT_BYTES: number; export declare const HOSTED_MAX_SNAPSHOT_BYTES: number; export declare const HOSTED_MAX_ISSUED_QUIDS = 1000000; export type HostedAuthorityFence = Readonly<{ logicalMapId: string; incarnationId: string; }>; export type HostedRegistryEntry = Readonly<{ name: string; /** Presence marks an Hson-owned entry; ordinary application entries retain their established shape. */ scope?: "hson-internal"; mode: LiveMapRootMode; schema: HsonSchema; schemaDigest: string; rootCodec: typeof HOSTED_ROOT_FORMAT; }>; export type HostedRegistry = Readonly<{ format: typeof HOSTED_REGISTRY_FORMAT; libraries: readonly HostedRegistryEntry[]; digest: string; }>; export type HostedRegistryBinding = Readonly<{ name: string; scope?: "hson-internal"; identity: LiveMapLibraryIdentity; mode: LiveMapRootMode; schema: HsonSchema; }>; export type HostedSemanticOperation = Readonly<{ library: string; operation: LiveMapAnyOp; }>; export type HostedReplayOperation = Readonly<{ library: string; domain: "data" | "graph"; kind: string; format: "structural-json" | typeof HOSTED_GRAPH_OP_FORMAT; payload: string; }>; export type HostedAggregateCommit = Readonly<{ format: typeof HOSTED_COMMIT_FORMAT; authority: HostedAuthorityFence; registryDigest: string; changed: boolean; prevRev: number; rev: number; operations: readonly HostedSemanticOperation[]; replay: Readonly<{ operations: readonly HostedReplayOperation[]; }>; }>; export type DecodedHostedOperation = Readonly<{ library: HostedRegistryBinding; semantic: LiveMapAnyOp; projected?: LiveMapProjectedDataOp; graph?: LiveMapGraphOp | LiveMapProjectedGraphEnsureQuidOp; }>; export declare class HostedAggregateRepresentationError extends Error { readonly operationIndex?: number | undefined; constructor(message: string, operationIndex?: number | undefined, options?: ErrorOptions); } export declare function make_hosted_registry(bindings: readonly HostedRegistryBinding[]): HostedRegistry; export declare function make_hosted_authority_fence(): HostedAuthorityFence; export declare function make_hosted_commit(fence: HostedAuthorityFence, registry: HostedRegistry, bindingsByIdentity: ReadonlyMap, input: Readonly<{ changed: boolean; prevRev: number; rev: number; operations: readonly Readonly<{ target: Readonly<{ library: LiveMapLibraryIdentity; }>; operation: LiveMapAnyOp; projected?: LiveMapProjectedDataOp; }>[]; }>): HostedAggregateCommit; export declare function decode_hosted_commit(input: HostedAggregateCommit, registry: HostedRegistry, bindingsByName: ReadonlyMap): readonly DecodedHostedOperation[]; export declare function encode_hosted_root(root: HsonNode): Readonly<{ format: typeof HOSTED_ROOT_FORMAT; payload: string; }>; export declare function decode_hosted_root(input: unknown): HsonNode; export declare function assert_libraries_snapshot_bound(snapshot: LiveMapLibrariesSnapshot): void; export declare function assert_libraries_snapshot_shape(snapshot: LiveMapLibrariesSnapshot): void; export declare function assert_hosted_libraries_snapshot_shape(snapshot: HostedLiveMapLibrariesSnapshot): void; /** Small universal synchronous SHA-256 used only for deterministic internal registry fingerprints. */ export declare function hosted_sha256(text: string): string; //# sourceMappingURL=livemap.hosted.d.ts.map