diff --git a/README.md b/README.md
index 25fb4c0..6d1ae0a 100644
--- a/README.md
+++ b/README.md
@@ -60,6 +60,10 @@ You can also have a look at the open items in the [project(s)](./projects), feel
# Change Log
Some of the changes that have major impact are listed here;
+### Updated September 2026
+- **fflib_SObjects2**
+ _getIdFieldValues_ **IMPORTANT BRACKING CHANGE** The method overload `Set getIdFieldValues(Schema.SObjectField field, Boolean omitNulls)` is now added to the fflib-apex-commons (and removed from the extensions), with the second parameter is flipped from `omitNulls` to `includeNulls`. So, when upgrading make sure to modify the `true` to `false` in your project!!!!
+
### Updates January 2026
- **fflib_ArrayUtils**
_copyFields_,
Add method that copies field values in bulk from one domain to another related domain
diff --git a/sfdx-project.json b/sfdx-project.json
index 4dda383..adee5c9 100644
--- a/sfdx-project.json
+++ b/sfdx-project.json
@@ -18,6 +18,9 @@
"fflibApexExtensions@0.7.0-1": "04tJ8000000kaKzIAI",
"fflibApexExtensions@0.8.0-1-apiUpgrade": "04tJ8000000kaL4IAI",
"fflibApexExtensions@0.9.0-1-feature/genericSelector": "04tJ8000000kaPHIAY",
- "fflibApexExtensions@0.10.0-1-api-upgrade-67": "04tJ9000000YW1CIAW"
+ "fflibApexExtensions@0.10.0-1-api-upgrade-67": "04tJ9000000YW1CIAW",
+ "fflibApexExtensions@0.11.0-1-code-reformat": "04tQy000000ZbBBIA0",
+ "fflibApexExtensions@0.11.0-2-code-reformat": "04tQy000000ZbEPIA0",
+ "fflibApexExtensions@0.11.0-3-code-reformat": "04tQy000000ZbKrIAK"
}
-}
+}
\ No newline at end of file
diff --git a/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicDomainFactory.cls b/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicDomainFactory.cls
index 87486bf..2757af7 100644
--- a/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicDomainFactory.cls
+++ b/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicDomainFactory.cls
@@ -1,6 +1,5 @@
/**
- * File Name: fflib_ClassicDomainFactory
- * @description Domain Factory for creating instances of Domain classes
+ * Domain Factory for creating instances of Domain classes
* using a static map for linking the SObjectType to its Domain Constructor implementation class
*
* @author architect ir. Wilhelmus G.J. Velzeboer
@@ -38,7 +37,7 @@ public virtual class fflib_ClassicDomainFactory
/**
* Constructs a Domain factory
**/
- public fflib_ClassicDomainFactory() {}
+ public fflib_ClassicDomainFactory(){ }
/**
* Constructs a Domain factory, based on a map linking the ObjectType to the
@@ -46,7 +45,7 @@ public virtual class fflib_ClassicDomainFactory
* Note: this will not check if the Apex classes actually implements the
* interfaces since this is not possible in the Apex runtime at present
*
- * @param selectorFactory, A reference to the Selector Factory instance, an instance of fflib_ISelectorFactory
+ * @param selectorFactory A reference to the Selector Factory instance, an instance of fflib_ISelectorFactory
* @param constructorTypeByObject Map of Domain classes by Object Type
**/
public fflib_ClassicDomainFactory(
@@ -84,7 +83,8 @@ public virtual class fflib_ClassicDomainFactory
* @param recordIds A list of Id's of the same type
*
* @return Instance of a Domain containing the queried records
- * @exception Throws an exception via the Selector Factory if the Ids are not all of the same SObjectType
+ *
+ * @throws DeveloperException If the Ids are not all of the same SObjectType
**/
public virtual override fflib_IDomain newInstance(Set recordIds)
{
@@ -100,12 +100,13 @@ public virtual class fflib_ClassicDomainFactory
* @param sObjectType The SObjectType of the given record Ids
*
* @return Instance of a Domain containing the queried records
- * @exception Throws an exception via the Selector Factory if the Ids are not all of the same SObjectType
+ *
+ * @throws DeveloperException If the Ids are not all of the same SObjectType
**/
public virtual fflib_IDomain newInstance(Set recordIds, Schema.SObjectType sObjectType)
{
// Avoid unexpected exceptions when the recordIds contains incorrect data
- if (recordIds.isEmpty() || new List(recordIds).get(0) == null )
+ if (recordIds.isEmpty() || new List(recordIds).get(0) == null)
return newInstance(new List(), sObjectType);
return newInstance(selectorFactory.selectById(recordIds));
diff --git a/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicSelectorFactory.cls b/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicSelectorFactory.cls
index d804232..9c39920 100644
--- a/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicSelectorFactory.cls
+++ b/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicSelectorFactory.cls
@@ -1,7 +1,4 @@
/**
- * File Name: fflib_ClassicSelectorFactory
- * @description
- *
* @author architect ir. Wilhelmus G.J. Velzeboer
*
* Copyright (c), W.G.J. Velzeboer,
diff --git a/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicServiceFactory.cls b/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicServiceFactory.cls
index d6f1b42..680fa0f 100644
--- a/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicServiceFactory.cls
+++ b/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicServiceFactory.cls
@@ -1,7 +1,4 @@
/**
- * File Name: fflib_ClassicServiceFactory
- * @description
- *
* @author architect ir. Wilhelmus G.J. Velzeboer
*
* Copyright (c), W.G.J. Velzeboer,
@@ -35,7 +32,9 @@ public virtual class fflib_ClassicServiceFactory
/**
* Constructs a simple Service Factory
**/
- public fflib_ClassicServiceFactory() {}
+ public fflib_ClassicServiceFactory()
+ {
+ }
/**
* Constructs a simple Service Factory,
diff --git a/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicUnitOfWorkFactory.cls b/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicUnitOfWorkFactory.cls
index 1395dbf..eaf96cc 100644
--- a/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicUnitOfWorkFactory.cls
+++ b/sfdx-source/apex-extensions/main/application/classic/classes/fflib_ClassicUnitOfWorkFactory.cls
@@ -1,7 +1,4 @@
/**
- * File Name: fflib_ClassicUnitOfWorkFactory
- * @description
- *
* @author architect ir. Wilhelmus G.J. Velzeboer
*
* Copyright (c), W.G.J. Velzeboer,
diff --git a/sfdx-source/apex-extensions/main/default/classes/domains/fflib_SObjects2.cls b/sfdx-source/apex-extensions/main/default/classes/domains/fflib_SObjects2.cls
index 42c6082..1fccef2 100644
--- a/sfdx-source/apex-extensions/main/default/classes/domains/fflib_SObjects2.cls
+++ b/sfdx-source/apex-extensions/main/default/classes/domains/fflib_SObjects2.cls
@@ -867,26 +867,6 @@ public virtual class fflib_SObjects2
return result;
}
- /**
- * Gets the Id values, but with the option to omit null values
- *
- * @param field The Schema.SObjectField to get their Id values
- * @param omitNulls If set to TRUE, null values will be removed from the result
- *
- * @return The Id values of the given sObjectField, null values are omitted
- */
- @TestVisible
- protected Set getIdFieldValues(Schema.SObjectField field, Boolean omitNulls)
- {
- Set result = getIdFieldValues(field);
-
- if (omitNulls)
- {
- result.remove(null);
- }
- return result;
- }
-
/**
* @param sObjectField The Schema.SObjectField to get their Id values
* @param criteria The criteria condition that must be met to include the value in the return
diff --git a/sfdx-source/apex-extensions/main/logger/classes/fflib_ALogAppenderFilter.cls b/sfdx-source/apex-extensions/main/logger/classes/fflib_ALogAppenderFilter.cls
index 76d415b..fd1b26d 100644
--- a/sfdx-source/apex-extensions/main/logger/classes/fflib_ALogAppenderFilter.cls
+++ b/sfdx-source/apex-extensions/main/logger/classes/fflib_ALogAppenderFilter.cls
@@ -37,9 +37,8 @@ public abstract with sharing class fflib_ALogAppenderFilter implements fflib_ILo
protected System.LoggingLevel minLogLevel = DEFAULT_LEVEL;
/**
- * setLoggingLevel
+ * Change the current minimum logging level
*
- * @description Change the current minimum logging level
* @param logLevel
*/
public void setLoggingLevel(System.LoggingLevel logLevel)
@@ -48,9 +47,8 @@ public abstract with sharing class fflib_ALogAppenderFilter implements fflib_ILo
}
/**
- * isValidLogLevel
+ * Compares the Organisation, User and Apex logging level settings
*
- * @description Compares the Organisation, User and Apex logging level settings
* @param logLevel
*
* @return Returns true if one of the settings is equal or higher than the given loglevel
@@ -59,33 +57,31 @@ public abstract with sharing class fflib_ALogAppenderFilter implements fflib_ILo
{
return (
isValidOrganisationLogLevel(logLevel) ||
- isValidUserLogLevel(logLevel) ||
- isValidApexClassLogLevel(logLevel)
+ isValidUserLogLevel(logLevel) ||
+ isValidApexClassLogLevel(logLevel)
);
}
/**
- * isValidLogLevel
+ * Compares the given log level valueToCompare against the compareTo
*
- * @description Compares the given log level valueToCompare against the compareTo
* @param compareTo The log level to compare against
* @param valueToCompare The log level to compare
*
* @return Returns true if the valueToCompare is equal of higher then the compareTo
*/
- private Boolean isValidLogLevel(System.LoggingLevel compareTo, System.LoggingLevel valueToCompare)
+ private static Boolean isValidLogLevel(System.LoggingLevel compareTo, System.LoggingLevel valueToCompare)
{
return compareTo != System.LoggingLevel.NONE
- &&
+ &&
valueToCompare != System.LoggingLevel.NONE
- &&
+ &&
valueToCompare.ordinal() >= compareTo.ordinal();
}
/**
- * isValidApexClassLogLevel
+ * Compare the given loglevel against the current Apex setting stored in this.minLogLevel
*
- * @description Compare the given loglevel against the current Apex setting stored in this.minLogLevel
* @param logLevel The log level to compare
*
* @return Returns true if the given log level is equal of higher then the Apex setting
@@ -96,9 +92,8 @@ public abstract with sharing class fflib_ALogAppenderFilter implements fflib_ILo
}
/**
- * isValidOrganisationLogLevel
+ * Compare the given loglevel against the Organisation setting stored in a Custom Setting
*
- * @description Compare the given loglevel against the Organisation setting stored in a Custom Setting
* @param logLevel The log level to compare
*
* @return Returns true if the given log level is equal of higher then the Organisation setting
@@ -112,9 +107,8 @@ public abstract with sharing class fflib_ALogAppenderFilter implements fflib_ILo
}
/**
- * isValidUserLogLevel
+ * Compare the given loglevel against the User setting stored in a Custom Setting
*
- * @description Compare the given loglevel against the User setting stored in a Custom Setting
* @param logLevel The log level to compare
*
* @return Returns true if the given log level is equal of higher then the User setting
@@ -158,20 +152,19 @@ public abstract with sharing class fflib_ALogAppenderFilter implements fflib_ILo
}
/**
- * hasSettingsValue
+ * Validates if the Custom Setting has a value stored in the given field
*
- * @description Validates if the Custom Setting has a value stored in the given field
* @param setting The Custom Setting to validate
* @param sObjectField The field to check
*
* @return Returns true is the given field is set in the Custom Setting
*/
- private Boolean hasSettingsValue(fflib_LogLevelFilter__c setting, SObjectField sObjectField)
+ private static Boolean hasSettingsValue(fflib_LogLevelFilter__c setting, SObjectField sObjectField)
{
return (
null != setting
&&
- setting.getPopulatedFieldsAsMap().containsKey(sObjectField.getDescribe().getName())
+ setting.getPopulatedFieldsAsMap().containsKey(sObjectField.getDescribe().getName())
);
}
diff --git a/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventAppender.cls b/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventAppender.cls
index a28ccf8..15ac62f 100644
--- a/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventAppender.cls
+++ b/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventAppender.cls
@@ -48,9 +48,8 @@ public virtual without sharing class fflib_LogEventAppender extends fflib_ALogAp
}
/**
- * publishEvents
+ * Publish the given fflib_LogEvent__e events and report if there are any errors
*
- * @description Publish the given fflib_LogEvent__e events and report if there are any errors
* @param events The Platform events to publish
*/
protected virtual void publishEvents(List events)
@@ -61,9 +60,8 @@ public virtual without sharing class fflib_LogEventAppender extends fflib_ALogAp
/**
- * checkAndReportErrors
+ * Iterate over the given Database.SaveResults and report any errors
*
- * @description Iterate over the given Database.SaveResults and report any errors
* @param saveResults
*/
protected void checkAndReportErrors(List saveResults)
@@ -79,9 +77,8 @@ public virtual without sharing class fflib_LogEventAppender extends fflib_ALogAp
}
/**
- * reportError
+ * Construct the error message for the failing Database.SaveResult and throws an exception
*
- * @description Construct the error message for the failing Database.SaveResult and throws an exception
* @param saveResult
*
* @throws fflib_LogEventAppender.fflib_LogEventAppenderException
diff --git a/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventDomain.cls b/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventDomain.cls
index 7115cac..44bd614 100644
--- a/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventDomain.cls
+++ b/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventDomain.cls
@@ -35,6 +35,8 @@ public abstract with sharing class fflib_LogEventDomain extends fflib_PlatformEv
/**
* Class constructor
+ *
+ * @param records
*/
public fflib_LogEventDomain(List records)
{
diff --git a/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventStoreListener.cls b/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventStoreListener.cls
index 3c133d5..6c949ce 100644
--- a/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventStoreListener.cls
+++ b/sfdx-source/apex-extensions/main/logger/classes/fflib_LogEventStoreListener.cls
@@ -32,6 +32,8 @@ public with sharing class fflib_LogEventStoreListener extends fflib_LogEventDoma
{
/**
* Class constructor
+ *
+ * @param records
*/
public fflib_LogEventStoreListener(List records)
{
diff --git a/sfdx-source/apex-extensions/main/logger/classes/fflib_Logger.cls b/sfdx-source/apex-extensions/main/logger/classes/fflib_Logger.cls
index 2e45421..3aac109 100644
--- a/sfdx-source/apex-extensions/main/logger/classes/fflib_Logger.cls
+++ b/sfdx-source/apex-extensions/main/logger/classes/fflib_Logger.cls
@@ -206,7 +206,7 @@ public with sharing class fflib_Logger implements fflib_ILogger
{
public void append(fflib_LogEntry logEntry)
{
- System.debug(logEntry.className + ' #' + logEntry.lineNumber + ' @'+ logEntry.methodName + ' ' + logEntry.message);
+ System.debug(logEntry.className + ' #' + logEntry.lineNumber + ' @' + logEntry.methodName + ' ' + logEntry.message);
}
}
diff --git a/sfdx-source/apex-extensions/main/logger/triggers/fflib_LogEventTrigger.trigger b/sfdx-source/apex-extensions/main/logger/triggers/fflib_LogEventTrigger.trigger
index ff45d1b..a9a1223 100644
--- a/sfdx-source/apex-extensions/main/logger/triggers/fflib_LogEventTrigger.trigger
+++ b/sfdx-source/apex-extensions/main/logger/triggers/fflib_LogEventTrigger.trigger
@@ -1,8 +1,9 @@
/**
- * File Name: sflib_LogEventTrigger
+ * File Name: sflib_LogEventTrigger
* Description: Tigger to store Log events into a custom object
* Copyright (c) 2019 Johnson & Johnson
- * @author: architect ir. Wilhelmus G.J. Velzeboer | wvelzebo@its.jnj.com
+ *
+ * @author architect ir. Wilhelmus G.J. Velzeboer | wvelzebo@its.jnj.com
*/
trigger fflib_LogEventTrigger on fflib_LogEvent__e (after insert)
{
diff --git a/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerActionConfig.cls b/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerActionConfig.cls
index a97c6d4..b2177e5 100644
--- a/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerActionConfig.cls
+++ b/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerActionConfig.cls
@@ -68,8 +68,8 @@ public virtual inherited sharing class fflib_TriggerActionConfig
// Get SObjectType
String ObjectTypeApiName =
String.isNotBlank(triggerAction.ObjectType__c)
- ? triggerAction.ObjectType__r?.QualifiedApiName?.toLowerCase().trim()
- : triggerAction.ObjectTypeAlternate__c.toLowerCase().trim();
+ ? triggerAction.ObjectType__r?.QualifiedApiName?.toLowerCase().trim()
+ : triggerAction.ObjectTypeAlternate__c.toLowerCase().trim();
this.sObjectType = Schema.describeSObjects(new List {ObjectTypeApiName}).get(0).getSObjectType();
}
diff --git a/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerActionConfigSelector.cls b/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerActionConfigSelector.cls
index 802bc3e..1ae26d2 100644
--- a/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerActionConfigSelector.cls
+++ b/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerActionConfigSelector.cls
@@ -78,15 +78,15 @@ public virtual without sharing class fflib_TriggerActionConfigSelector
}
)
- /* Please replace the above String.format method call for that below,
- when the following issue in fflib-apex-commons is resolved:
- https://github.com/apex-enterprise-patterns/fflib-apex-common/issues/208
+ /* Please replace the above String.format method call for that below,
+ when the following issue in fflib-apex-commons is resolved:
+ https://github.com/apex-enterprise-patterns/fflib-apex-common/issues/208
- newQueryFactory()
- .selectField('ObjectType__r.QualifiedApiName')
- .toSOQL()
+ newQueryFactory()
+ .selectField('ObjectType__r.QualifiedApiName')
+ .toSOQL()
- */
+ */
);
}
}
\ No newline at end of file
diff --git a/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerContext.cls b/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerContext.cls
index 89bdeea..76fe1ad 100644
--- a/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerContext.cls
+++ b/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerContext.cls
@@ -52,7 +52,8 @@ public virtual inherited sharing class fflib_TriggerContext
* Provides access to the Trigger.new and allowing it to be mocked in unit-tests
*/
@TestVisible
- protected List records {
+ protected List records
+ {
get
{
if (records == null)
@@ -88,8 +89,10 @@ public virtual inherited sharing class fflib_TriggerContext
}
/**
- * Provides access to the data represented by this Trigger Context
- **/
+ * Provides access to the data represented by this Trigger Context
+ *
+ * @return
+ **/
public System.TriggerOperation getTriggerOperation()
{
return triggerOperation;
@@ -131,18 +134,26 @@ public virtual inherited sharing class fflib_TriggerContext
}
/**
- * Detects whether any values in context records have changed for given field as string
- * Returns list of SObject records that have changes in the specified fields
- **/
+ * Detects whether any values in context records have changed for given field as string
+ * Returns list of SObject records that have changes in the specified fields
+ *
+ * @param fieldName
+ *
+ * @return
+ **/
public List getChangedRecords(String fieldName)
{
return getChangedRecords(new Set {fieldName});
}
/**
- * Detects whether any values in context records have changed for given fields as strings
- * Returns list of SObject records that have changes in the specified fields
- **/
+ * Detects whether any values in context records have changed for given fields as strings
+ * Returns list of SObject records that have changes in the specified fields
+ *
+ * @param fieldNames
+ *
+ * @return
+ **/
public List getChangedRecords(Set fieldNames)
{
List changedRecords = new List();
@@ -167,6 +178,10 @@ public virtual inherited sharing class fflib_TriggerContext
/**
* Detects whether any values in context records have changed for given field as token
* Returns list of SObject records that have changes in the specified fields
+ *
+ * @param fieldToken
+ *
+ * @return
**/
public List getChangedRecords(Schema.SObjectField fieldToken)
{
@@ -176,6 +191,10 @@ public virtual inherited sharing class fflib_TriggerContext
/**
* Detects whether any values in context records have changed for given fields as tokens
* Returns list of SObject records that have changes in the specified fields
+ *
+ * @param fieldTokens
+ *
+ * @return
**/
public List getChangedRecords(Set fieldTokens)
{
@@ -200,6 +219,8 @@ public virtual inherited sharing class fflib_TriggerContext
/**
* Provides access to Trigger.oldMap or the mock when configured in a unit-test
+ *
+ * @return
**/
public Map getExistingRecords()
{
diff --git a/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerHandler.cls b/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerHandler.cls
index d1cb027..901e212 100644
--- a/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerHandler.cls
+++ b/sfdx-source/apex-extensions/main/triggerHandler/classes/fflib_TriggerHandler.cls
@@ -34,7 +34,7 @@ public virtual with sharing class fflib_TriggerHandler
/**
* Retains the trigger tracking configuration used for each domain
- **/
+ **/
private static Map triggerEventByClass;
private static Boolean disabled = false;
@@ -90,7 +90,7 @@ public virtual with sharing class fflib_TriggerHandler
public static fflib_SObjectDomain.TriggerEvent getTriggerEvent(Type triggerActionClass)
{
- if(!triggerEventByClass.containsKey(triggerActionClass))
+ if (!triggerEventByClass.containsKey(triggerActionClass))
{
triggerEventByClass.put(triggerActionClass, new fflib_SObjectDomain.TriggerEvent());
}
@@ -191,7 +191,7 @@ public virtual with sharing class fflib_TriggerHandler
for (fflib_TriggerAction__mdt action : selector.selectAllActive())
{
- configs.add( new fflib_TriggerActionConfig(action));
+ configs.add(new fflib_TriggerActionConfig(action));
}
}
diff --git a/sfdx-source/apex-extensions/main/triggerHandler/classes/interfaces/fflib_ITriggerContext.cls b/sfdx-source/apex-extensions/main/triggerHandler/classes/interfaces/fflib_ITriggerContext.cls
index 29511b8..9d7ee63 100644
--- a/sfdx-source/apex-extensions/main/triggerHandler/classes/interfaces/fflib_ITriggerContext.cls
+++ b/sfdx-source/apex-extensions/main/triggerHandler/classes/interfaces/fflib_ITriggerContext.cls
@@ -30,31 +30,49 @@
public interface fflib_ITriggerContext
{
/**
- * Detects whether any values in context records have changed for given field as string
- * Returns list of SObject records that have changes in the specified fields
- **/
+ * Detects whether any values in context records have changed for given field as string
+ * Returns list of SObject records that have changes in the specified fields
+ *
+ * @param fieldName
+ *
+ * @return
+ **/
List getChangedRecords(String fieldName);
/**
- * Detects whether any values in context records have changed for given fields as strings
- * Returns list of SObject records that have changes in the specified fields
- **/
+ * Detects whether any values in context records have changed for given fields as strings
+ * Returns list of SObject records that have changes in the specified fields
+ *
+ * @param fieldNames
+ *
+ * @return
+ **/
List getChangedRecords(Set fieldNames);
/**
* Detects whether any values in context records have changed for given field as token
* Returns list of SObject records that have changes in the specified fields
+ *
+ * @param fieldToken
+ *
+ * @return
**/
- List getChangedRecords(Schema.SObjectField fieldToken);
+ List getChangedRecords(Schema.SObjectField fieldToken);
/**
- * Detects whether any values in context records have changed for given fields as tokens
+ * Detects whether any values in context records have changed for given fields as tokens
* Returns list of SObject records that have changes in the specified fields
+ *
+ * @param fieldTokens
+ *
+ * @return
**/
List getChangedRecords(Set fieldTokens);
/**
* Provides access to Trigger.oldMap or the mock when configured in a unit-test
+ *
+ * @return
**/
Map getExistingRecords();
@@ -64,8 +82,10 @@ public interface fflib_ITriggerContext
System.TriggerOperation getTriggerOperation();
/**
- * Provides access to the data represented by this Trigger Context
- **/
+ * Provides access to the data represented by this Trigger Context
+ *
+ * @return
+ **/
List getRecords();
/**