import type { TransformStep, TransformStepResult } from './transforms.js'; /** Signature of a compiled custom/formula expression: `(value, fields) => result`. */ export type CompiledExpression = (value: unknown, fields: Record) => unknown; /** * Framework-agnostic engine that runs a field-value transform pipeline over a single `(value, fields)` * pair. Lifted from the MemberJunction integration field-mapping engine so the integration sync AND the * rules-based bulk-update processor share one implementation of every transform type. * * Holds an LRU cache of compiled custom/formula expressions (an identical expression compiles once, not * once per record). A failed compile is cached as the `Error` it threw and re-thrown from cache, so a * malformed expression is compiled exactly once across a whole batch. */ export declare class FieldTransformEngine { private readonly compiledExpressionCache; /** * Runs `value` through every step of `steps`, returning the final value (or `Skipped` when an * OnError='Skip' step drops the field). `fields` is the full record, available to combine/custom steps. */ ExecutePipeline(value: unknown, fields: Record, steps: TransformStep[]): TransformStepResult; /** * Executes a single transform step, applying the configured transformation and handling errors * according to the step's OnError strategy (default 'Null' — grace: null the field, keep going). */ ExecuteStep(step: TransformStep, value: unknown, fields: Record): TransformStepResult; /** * Evaluates a value-producing expression against the record. Reuses the compiled-expression cache. * The expression sees the current field value as `value` and all record fields as `fields` * (e.g. `fields.FirstName + ' ' + fields.LastName`). */ Evaluate(expression: string, value: unknown, fields: Record): unknown; private dispatch; private handleError; private applyDirect; private applyRegex; private applySplit; private applyCombine; private applyLookup; private applyFormat; private applyCoerce; private applySubstring; private getCompiled; private compile; } //# sourceMappingURL=FieldTransformEngine.d.ts.map