import type { DataDomainGraph, SerializedGraph, DeserializationResult, DeserializeOptions } from './types.js';
import type { DataDomain } from './DataDomain.js';
interface GraphMergeResult {
    /**
     * The set of node ids generated for the foreign nodes.
     */
    nodes: Set<string>;
    /**
     * The set of edge ids generated for the foreign edges.
     */
    edges: Set<string>;
}
export declare function serialize(g: DataDomainGraph, domainKey: string): SerializedGraph;
/**
 * Removes all foreign nodes, edges, and parents from the graph.
 * @param g The graph to remove the foreign nodes from
 * @param domainKey The key of the domain to remove
 */
export declare function removeForeignGraph(g: DataDomainGraph, domainKey: string): void;
/**
 * Merges a foreign domain graph into the current domain graph.
 * @param own Our domain graph
 * @param foreign The foreign domain graph
 * @param domain The key of the foreign domain
 */
export declare function mergeGraph(own: DataDomainGraph, foreign: DataDomainGraph, domain: string): GraphMergeResult;
/**
 * To deserialize a graph:
 *
 * - Create a new DataDomain instance
 * - Restore all foreign nodes and edges
 * - Call the deserialize function
 *
 * @param root The DataDomain instance to use as the root for the graph
 * @param json The previously serialized graph
 * @param dependencies An array of foreign data domains to register with this domain
 * @param mode The deserialization mode - 'strict' throws errors, 'lenient' collects issues
 * @returns DeserializationResult with graph, issues, and success status
 * @throws Error in strict mode when any issue is encountered
 */
export declare function deserialize(root: DataDomain, options?: DeserializeOptions): DeserializationResult;
export {};
//# sourceMappingURL=DomainSerialization.d.ts.map