- All Superinterfaces:
ModelLink
Represents a link between two entity models based on a foreign key.
The master selection is applied to the detail once: a selection the link has already applied is ignored, whether it arrives with the link being activated anew or with the master refreshing and notifying with fresher instances of the same rows. A detail condition changed by hand therefore survives navigation and refresh, a changed master selection overrules it.
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final PropertyValue<Boolean> Specifies whether a linked model clears the foreign key search condition when null or no value is selected in a parent model Value type: Boolean Default value: truestatic final PropertyValue<Boolean> Specifies whether a linked model sets the parent foreign key value to null when null or no value is selected in a parent model Value type: Boolean Default value: falsestatic final PropertyValue<Boolean> Specifies whether a linked model should be automatically refreshed when the selection in the parent model changes.static final PropertyValue<Boolean> Specifies whether a linked model should automatically search by the entity inserted by the parent model.static final PropertyValue<Boolean> Specifies whether a linked model should automatically set the foreign key value to the entity inserted by the parent model. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Returns a newForeignKeyModelLink.Builder.ModelStepinstance.
-
Field Details
-
SET_VALUE_ON_INSERT
Specifies whether a linked model should automatically set the foreign key value to the entity inserted by the parent model.- Value type: Boolean
- Default value: true
-
SET_CONDITION_ON_INSERT
Specifies whether a linked model should automatically search by the entity inserted by the parent model.- Value type: Boolean
- Default value: false
-
REFRESH_ON_SELECTION
Specifies whether a linked model should be automatically refreshed when the selection in the parent model changes.- Value type: Boolean
- Default value: true
-
CLEAR_VALUE_ON_EMPTY_SELECTION
Specifies whether a linked model sets the parent foreign key value to null when null or no value is selected in a parent model- Value type: Boolean
- Default value: false
-
CLEAR_CONDITION_ON_EMPTY_SELECTION
Specifies whether a linked model clears the foreign key search condition when null or no value is selected in a parent model- Value type: Boolean
- Default value: true
-
-
Method Details
-
foreignKey
ForeignKey foreignKey()- Returns:
- the foreign key this link is based on
-
builder
Returns a new
ForeignKeyModelLink.Builder.ModelStepinstance.- Returns:
- a
ForeignKeyModelLink.Builder.ModelStepinstance
-