-
Notifications
You must be signed in to change notification settings - Fork 0
The Plugin Framework
Apex Database Layer includes a mechanism to inject custom logic, or "plugins" in certain corners of the application. Use this plugin framework to make the framework your own!
💡 Have an idea for a new plugin? Create an issue.
The framework includes a custom metadata type, Database Layer Setting / DatabaseLayerSetting__mdt.
Note: This object is _optional - you do not need to create any records to enable the framework's core functionality._
To leverage the plugin framework, create a DatabaseLayerSetting__mdt record. There can only be one such record, and it must be called "Default":
Each plugin looks at field(s) in the Plugins section on the custom metadata record. For example, Dml.PreAndPostProcessor uses an apex class named in the DML: Pre & Post Processor field to perform its logic.
-
Dml.PreAndPostProcessor: Defines logic to be run immediately before and/or immediately after a DML operation. Use this plugin for specialized logic, like logging, for example.
-
Soql.PreAndPostProcessor: Defines logic to be run immediately before and/or immediately after a SOQL operation. Use this plugin for specialized logic, like logging, for example.
- Generating Test Records
- Dml
- Soql
- Cmdt
- Plugins
- DatabaseLayer
- Dml
- MockDml
- MockRecord
- Cmdt
- MockCmdt
- MockSoql
-
Soql
- Soql.AggregateResult
- Soql.Aggregation
- Soql.Binder
- Soql.Builder
- Soql.Condition
- Soql.ConditionalLogic
- Soql.Criteria
- Soql.Cursor
- Soql.Function
- Soql.InnerQuery
- Soql.InvalidParameterValueException
- Soql.LogicType
- Soql.NullOrder
- Soql.Operation
- Soql.Operator
- Soql.ParentField
- Soql.PreAndPostProcessor
- Soql.QueryLocator
- Soql.Request
- Soql.Scope
- Soql.Selectable
- Soql.SortDirection
- Soql.SortOrder
- Soql.Subquery
- Soql.TypeOf
- Soql.Usage
- Soql.WhenClause