import { TreeNode } from "fluid-framework"; import { Dispatch, SetStateAction } from "react"; /** * @internal * Build a proxied version of a node and set its value to the treeMap provided * * @param rawNode the raw proxy node exposed by Fluid * @param treeMap a map where Fluid's proxy node is mapped to our proxied node * @returns TNode instance */ export declare function buildProxy(rawNode: TNode, treeMap: WeakMap): TNode; /** * @internal * Set up listeners for a given TreeNode. * Will recursively call this function for all children nodes of each children until there are no more child nodes. * * @param parentRawNode raw parent node * @param rootNodeForListener root node being listened to in useTreeNode * @param treeMap a map where Fluid's proxy node is mapped to our proxied node * @param unsubscribeListeners list of unsubscribe listeners, where we set the unsubscribe callbacks * @param setProxyNode setter to set the root proxy node listened to in useTreeNode */ export declare function setUpListenersForNodeChildren(parentRawNode: TreeNode, rootNodeForListener: TreeNode, treeMap: WeakMap, unsubscribeListeners: (() => void)[], setProxyNode: Dispatch>): void; /** * @internal * Fluid only knows how to work with their proxied version of a TreeNode. * We store a reference to that node in our proxied instances so we can easily use it when working with Fluid APIs. * * @param node get the raw node from the proxy * @returns the raw proxied node that Fluid expects */ export declare function getRawNode(node: TNode): TNode; //# sourceMappingURL=tree-node-utils.d.ts.map