Centralized Salesforce Development Framework

Scott Covert (scott.b.covert@gmail.com)
Home
AccountAfterDeleteTriggerHandler
AccountAfterInsertTriggerHandler
AccountAfterUnDeleteTriggerHandler
AccountAfterUpdateTriggerHandler
AccountBeforeDeleteTriggerHandler
AccountBeforeInsertTriggerHandler
AccountBeforeUpdateTriggerHandler
AccountHelper
AccountTriggerDispatcher
AccountsTest
CalloutHandler
ConfigService
CustomException
DMLManager
DataFactoryService
DataFactoryServiceTest
DateService
DateServiceTest
DiagnosticsInstrumentation
HttpCalloutMockService
ITriggerDispatcher
ITriggerHandler
QueueableDispatcher
QueueableHandler
QueueableHandlerTest
RepeatingBatch
RepeatingFuture
SObjectService
SObjectServiceTest
ScheduleHandler
ScheduledDispatcher
TestVerificationService
Test_DMLManager
TriggerDispatcherBase
TriggerFactory
TriggerHandlerBase
TriggerParameters

TriggerHandlerBase

public abstract class TriggerHandlerBase implements ITriggerHandler
DescriptionThis class implements the ITriggerHandler to provide abstract/virtual methods for the interface methods and so that the trigger handlers need to implement only the method that they have to. The only exception is the mainEntry, which is mandatory for the trigger handlers to implement.
AuthorScott Covert
Date11/9/2014

  Properties

SimulateConcurrencyError
@TestVisible private static List<Boolean> SimulateConcurrencyError
Determines if a concurrency error should be simulated for test purposes
sObjectsToUpdate
protected Map<Id, SObject> sObjectsToUpdate
Map of sobjects to update at the end of the trigger event

Methods

  batchEntry

public virtual void batchEntry(TriggerParameters tp)
DescriptionCalled by batch apex. The trigger handlers can choose to ignore this method if they want batch entries to behave no differently than main entries.
AuthorScott Covert
Date11/9/2014
Parameters
TriggerParametersThe trigger parameters such as the list of records before and after the update.

  futureEntry

public virtual void futureEntry(TriggerParameters tp)
DescriptionCalled by asynchronous function. The trigger handlers can choose to ignore this method if they want future entries to behave no differently than main entries.
AuthorScott Covert
Date11/9/2014
Parameters
TriggerParametersThe trigger parameters such as the list of records before and after the update.

  inProgressEntry

public virtual void inProgressEntry(TriggerParameters tp)
DescriptionCalled for the subsequent times in the same execution context. The trigger handlers can choose to ignore if they don't need the reentrant feature.
AuthorScott Covert
Date11/9/2014
Parameters
TriggerParametersThe trigger parameters such as the list of records before and after the update.

  mainEntry

public abstract void mainEntry(TriggerParameters tp)
DescriptionCalled for the first time in the execution context. The trigger handlers need to implement this method.
AuthorScott Covert
Date11/9/2014
Parameters
TriggerParametersThe trigger parameters such as the list of records before and after the update.

  queueableEntry

public virtual void queueableEntry(TriggerParameters tp)
DescriptionCalled by queueable function. The trigger handlers can choose to ignore this method if they want queueable entries to behave no differently than main entries.
AuthorScott Covert
Date2/26/2016
Parameters
TriggerParametersThe trigger parameters such as the list of records before and after the update.

  scheduledEntry

public virtual void scheduledEntry(TriggerParameters tp)
DescriptionCalled by scheduled apex. The trigger handlers can choose to ignore this method if they want scheduled entries to behave no differently than main entries.
AuthorScott Covert
Date11/9/2014
Parameters
TriggerParametersThe trigger parameters such as the list of records before and after the update.

  updateObjects

public virtual void updateObjects()
DescriptionUpdates the objects (if any). Concurrency errors will be silently logged while any other errors will throw an exception.
AuthorScott Covert
Date11/9/2014