Enum Class DynamicDefaultValueBehavior
java.lang.Object
java.lang.Enum<DynamicDefaultValueBehavior>
com.kingsrook.qqq.backend.core.model.metadata.fields.DynamicDefaultValueBehavior
- All Implemented Interfaces:
FieldBehavior<DynamicDefaultValueBehavior>
,Serializable
,Comparable<DynamicDefaultValueBehavior>
,Constable
public enum DynamicDefaultValueBehavior
extends Enum<DynamicDefaultValueBehavior>
implements FieldBehavior<DynamicDefaultValueBehavior>
Field behavior that sets a default value for a field dynamically.
e.g., create-date fields get set to 'now' on insert.
e.g., modify-date fields get set to 'now' on insert and on update.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionvoid
apply
(ValueBehaviorApplier.Action action, List<QRecord> recordList, QInstance instance, QTableMetaData table, QFieldMetaData field) Apply this behavior to a list of recordsIn case a behavior of this type wasn't set on the field, what should the default of this type be?static DynamicDefaultValueBehavior
Returns the enum constant of this class with the specified name.static DynamicDefaultValueBehavior[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class java.lang.Enum
clone, compareTo, describeConstable, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
Methods inherited from interface com.kingsrook.qqq.backend.core.model.metadata.fields.FieldBehavior
allowMultipleBehaviorsOfThisType, validateBehaviorConfiguration
-
Enum Constant Details
-
CREATE_DATE
-
MODIFY_DATE
-
USER_ID
-
NONE
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
getDefault
Description copied from interface:FieldBehavior
In case a behavior of this type wasn't set on the field, what should the default of this type be?- Specified by:
getDefault
in interfaceFieldBehavior<DynamicDefaultValueBehavior>
-
apply
public void apply(ValueBehaviorApplier.Action action, List<QRecord> recordList, QInstance instance, QTableMetaData table, QFieldMetaData field) Description copied from interface:FieldBehavior
Apply this behavior to a list of records- Specified by:
apply
in interfaceFieldBehavior<DynamicDefaultValueBehavior>
-