import 'reflect-metadata'; import type { ChronicleClassDecorator } from '../../types/standardDecoratorMetadata.js'; /** Options for the edgeFrom class decorator. */ export interface EdgeFromOptions { /** The name of the event property that holds the key of the source node. */ readonly sourceKey: string; /** The name of the event property that holds the key of the target node. */ readonly targetKey: string; /** The name of the event property that holds the identity of the edge, for an edge type with an identifying property. */ readonly identity?: string; } /** Metadata stored by the edgeFrom class decorator. */ export interface EdgeFromMetadata extends EdgeFromOptions { /** The event constructor. */ readonly eventType: Function; } /** * Class decorator that creates or updates an edge when an event is observed. Both end nodes are created without * properties when they do not exist. * @param eventType - The event constructor. * @param options - The event properties that hold the keys of the end nodes and, optionally, the identity of the edge. * @returns A class decorator. */ export declare function edgeFrom(eventType: Function, options: EdgeFromOptions): ChronicleClassDecorator; /** * Retrieves all edgeFrom metadata stored on the given class constructor. * @param target - The class constructor. * @returns An array of edgeFrom metadata entries. */ export declare function getEdgeFromMetadata(target: Function): EdgeFromMetadata[]; //# sourceMappingURL=edgeFrom.d.ts.map