Interface EntityFormatter.Builder
- Enclosing interface:
EntityFormatter
public static sealed interface EntityFormatter.Builder
A Builder for a formatter, which provides toString() values for entities.
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Adds the given static text to thisEntityFormatter.BuilderAdds the value of the given attribute to thisEntityFormatter.Buildervalue(ForeignKey foreignKey, Attribute<?> attribute) Adds the value mapped to the given attribute in theEntityinstance mapped to the given foreign key to thisEntityFormatter.Builder
-
Method Details
-
value
Adds the value of the given attribute to thisEntityFormatter.Builder- Parameters:
attribute- the attribute which value should be added to the string representation- Returns:
- this
EntityFormatter.Builderinstance
-
value
Adds the value mapped to the given attribute in theEntityinstance mapped to the given foreign key to thisEntityFormatter.Builder- Parameters:
foreignKey- the foreign keyattribute- the attribute in the referenced entity to use- Returns:
- this
EntityFormatter.Builderinstance
-
text
Adds the given static text to thisEntityFormatter.Builder- Parameters:
text- the text to add- Returns:
- this
EntityFormatter.Builderinstance
-
build
EntityFormatter build()- Returns:
- a new EntityFormatter based on this builder
-