Skip to content

Commit 69395ad

Browse files
committed
Add section about projection modification after loading.
1 parent 4b41763 commit 69395ad

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/main/asciidoc/object-mapping/projections.adoc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,14 @@ the projection logic will not follow those cycles but only create cycle-free que
6262
Multi-level projections are bounded to the entities they should project.
6363
`RelationshipProperties` fall into the category of entities in this case and needs to get respected if projections get applied.
6464

65+
[[projections.sdn.manipulation]]
66+
== Data manipulation of projections
67+
68+
If you have fetched the projection as a DTO, you can modify its values.
69+
But in case you are using the interface-based projection, you cannot just update the interface.
70+
A typical pattern that can be used is to provide a method in your domain entity class that consumes the interface and creates a domain entity with the copied values from the interface.
71+
This way, you can then update the entity and persist it again with the projection blueprint/mask as described in the next section.
72+
6573
[[projections.sdn.persistence]]
6674
== Persistence of projections
6775

0 commit comments

Comments
 (0)