Skip to content

UTIL_FormulaFilter.INT_SObjectFormulaEvaluationContext

Class

apex
global interface UTIL_FormulaFilter.INT_SObjectFormulaEvaluationContext

Known Derived Types: UTIL_FormulaContext.AccountContext, UTIL_FormulaContext.CampaignContext, UTIL_FormulaContext.CaseContext, UTIL_FormulaContext.ContactContext, UTIL_FormulaContext.EventContext, UTIL_FormulaContext.FoobarContext, UTIL_FormulaContext.LeadContext, UTIL_FormulaContext.OpportunityContext, UTIL_FormulaContext.TaskContext, UTIL_FormulaContext.UserContext

Interface for providing context data to dynamic formula evaluations using Salesforce's FormulaEval namespace. Implementing classes supply the necessary context for evaluating formulas using SObjects.


Methods

MethodDescription
global abstract void setContext(SObject oldRecord, SObject newRecord)Sets the context for formula evaluation by providing the current and previous states of the SObject record being processed.

setContext

apex
global abstract void setContext(SObject oldRecord, SObject newRecord)

Sets the context for formula evaluation by providing the current and previous states of the SObject record being processed. This method is invoked during trigger execution to supply the formula with relevant data for evaluation.

Parameters

ParameterTypeDescription
oldRecordSObjectThe state of the record before the DML operation.
newRecordSObjectThe state of the record after the DML operation.