DATAJDBC-111 - Polishing.
Formatting. Removed some redundant tests. Some code simplifications. Original pull request: #110.
This commit is contained in:
@@ -124,7 +124,8 @@ The properties of the following types are currently supported:
|
||||
It is optional for one-to-one relationship entities to have an `id` attribute.
|
||||
The table of the referenced entity is expected to have an additional column named the same as the table of the referencing entity.
|
||||
You can change this name by implementing `NamingStrategy.getReverseColumnName(RelationalPersistentProperty property)`.
|
||||
Embedded entities do not have an `id`.
|
||||
Embedded entities do not need an `id`.
|
||||
If one is present it gets ignored.
|
||||
|
||||
* `Set<some entity>` is considered a one-to-many relationship.
|
||||
The table of the referenced entity is expected to have an additional column named the same as the table of the referencing entity.
|
||||
@@ -273,7 +274,7 @@ public class MySubEntity {
|
||||
====
|
||||
|
||||
[[jdbc.entity-persistence.embedded-entities]]
|
||||
=== `Embedded entities`
|
||||
=== Embedded entities
|
||||
|
||||
Embedded entities are used to have value objects in your java data model, even if there is only one table in your database.
|
||||
In the following example you see, that `MyEntity` is mapped with the `@Embedded` annotation.
|
||||
@@ -299,7 +300,6 @@ public class EmbeddedEntity {
|
||||
If you need a value object multiple times in an entity, this can be achieved with the optional `value` element of the `@Embedded` annotation.
|
||||
This element represents a prefix and is prepend for each column name in the embedded object.
|
||||
|
||||
|
||||
[[jdbc.entity-persistence.state-detection-strategies]]
|
||||
=== Entity State Detection Strategies
|
||||
|
||||
|
||||
Reference in New Issue
Block a user