/** * Workflow Utility Functions * * Helper functions for template rendering, path extraction, and ID generation. * * @module execution/workflow/utils */ /** * Generate a unique ID with a given prefix * * @param prefix - Prefix for the ID (e.g., 'execution', 'checkpoint') * @returns Unique ID string * * @example * ```typescript * const id = generateId('execution'); * // Returns: 'execution-1234567890-abc123' * ``` */ export declare function generateId(prefix?: string): string; /** * Render a template string by replacing {{variable}} placeholders with context values * * @param template - Template string with {{variable}} placeholders * @param context - Context object containing variable values * @returns Rendered string with variables replaced * * @example * ```typescript * const context = { name: 'World', greeting: 'Hello' }; * const result = renderTemplate('{{greeting}} {{name}}!', context); * // Returns: 'Hello World!' * ``` */ export declare function renderTemplate(template: string, context: Record): string; /** * Extract a value from an object using a dot-notation path * * @param obj - Object to extract value from * @param path - Dot-notation path (e.g., 'user.profile.name') * @returns Extracted value or undefined if path doesn't exist * * @example * ```typescript * const obj = { user: { profile: { name: 'Alice' } } }; * const name = extractValue(obj, 'user.profile.name'); * // Returns: 'Alice' * ``` */ export declare function extractValue(obj: any, path: string): any; /** * Merge two context objects, with the second overriding the first * * @param base - Base context object * @param updates - Updates to merge into base * @returns New merged context object * * @example * ```typescript * const base = { a: 1, b: 2 }; * const updates = { b: 3, c: 4 }; * const merged = mergeContext(base, updates); * // Returns: { a: 1, b: 3, c: 4 } * ``` */ export declare function mergeContext(base: Record, updates: Record): Record; /** * Evaluate a condition string in the context * * @param condition - Condition string to evaluate (e.g., '{{isEnabled}}') * @param context - Context object * @returns Boolean result of condition * * @example * ```typescript * const context = { isEnabled: true }; * const result = evaluateCondition('{{isEnabled}}', context); * // Returns: true * ``` */ export declare function evaluateCondition(condition: string, context: Record): boolean; /** * Create initial workflow context * * @param initialValues - Initial context values * @returns New context object */ export declare function createContext(initialValues?: Record): Record; //# sourceMappingURL=utils.d.ts.map