export type ChildAccessorResolver = (node: Node, accessorName: string) => unknown; /** * the property name a child is exposed as: `EnabledState` -> `enabledState`, `EURange` -> `euRange`. * The mapping is not invertible, hence the registry kept by {@link registerChildName}. */ export declare function childAccessorName(browseName: string): string; export declare function hasSharedChildAccessor(accessorName: string): boolean; /** the names no child may claim on any node, see {@link isReservedChildAccessorName} */ export declare function reservedChildAccessorNames(): readonly string[]; /** * true for the names no child may claim on any node, shared getter or own accessor alike: * `then` would turn every node into a thenable, `__proto__` would corrupt it */ export declare function isReservedChildAccessorName(accessorName: string): boolean; export declare function registerChildName(browseName: string | null | undefined, requestShared: boolean): string | undefined; /** how much the registries hold, for the tests that check they stay bounded by the nodeset vocabulary */ export declare function childAccessorRegistrySizes(): { accessorNames: number; irregularNames: number; shared: number; pending: number; }; /** * Define the shared getter of every accessor name queued by {@link registerChildName}. * * @returns the number of getters defined */ export declare function defineSharedChildAccessors(prototype: Node, resolve: ChildAccessorResolver): number; export interface IndexedChild { node?: unknown; } /** * The child that `parent.` designates, given the parent's child index * (browse name -> reference, or references when several children share a browse name) and * which references count: the index holds every hierarchical reference, while a dotted child * is one reached through a structural reference (a component, a property, a subtype, an * organized node), not through an event reference such as HasNotifier. * * The capitalised name is tried first, then the accessor name itself, then the irregular * browse names on record; among children sharing a browse name the first one indexed wins, * which is what the own-accessor installation did too. */ export declare function resolveChildInIndex(index: Map, accessorName: string, accept: (reference: Child) => boolean): Child["node"] | undefined;