File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -7,14 +7,14 @@ The following table describes the strategies that Spring Data offers for detecti
7
7
[options = "autowidth",cols="1,1"]
8
8
|===
9
9
|`@Id`-Property inspection (the default)
10
- |By default, Spring Data inspects the id property of the given entity.
11
- If the id property is `null` or `0` in case of primitive types, then the entity is assumed to be new.
10
+ |By default, Spring Data inspects the identifier property of the given entity.
11
+ If the identifier property is `null` or `0` in case of primitive types, then the entity is assumed to be new.
12
12
Otherwise, it is assumed to not be new.
13
13
14
14
|`@Version`-Property inspection
15
15
|If a property annotated with `@Version` is present and `null`, or in case of a version property of primitive type `0` the entity is considered new.
16
16
If the version property is present but has a different value, the entity is considered to not be new.
17
- If no version property is present Spring Data falls back to inspection of the id property.
17
+ If no version property is present Spring Data falls back to inspection of the identifier property.
18
18
19
19
|Implementing `Persistable`
20
20
|If an entity implements `Persistable`, Spring Data delegates the new detection to the `isNew(…)` method of the entity.
You can’t perform that action at this time.
0 commit comments