- All Known Implementing Classes:
DefaultAuditProvider
An SPI to provide audit fields.
For convenience, consider extending DefaultAuditProvider
instead of
implementing this interface. This will prevent compilation errors in future
versions of jOOQ, when this interface might get new methods.
- Author:
- Lukas Eder
-
Method Summary
Modifier and TypeMethodDescription<T> @Nullable Field<T>
provideTimestamp
(GeneratorContext<?, ?, T> ctx) Provide a temporal expression for auditing, defaulting toDSL.currentDate()
,DSL.currentTime()
, orDSL.currentTimestamp()
, depending on the argument data type.<T> @Nullable Field<T>
provideUser
(GeneratorContext<?, ?, T> ctx) Provide a credential expression for auditing, defaulting toDSL.currentUser()
.
-
Method Details
-
provideTimestamp
Provide a temporal expression for auditing, defaulting toDSL.currentDate()
,DSL.currentTime()
, orDSL.currentTimestamp()
, depending on the argument data type.- Returns:
- The temporal expression, or
null
if no expression is available.
-
provideUser
Provide a credential expression for auditing, defaulting toDSL.currentUser()
.- Returns:
- The credential expression, or
null
if no expression is available.
-