Timeline for In DDD, is the root aggregate who has to expose the methods to tell if a child entity can be create or update?
Current License: CC BY-SA 4.0
4 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Apr 20, 2023 at 7:34 | vote | accept | Álvaro García | ||
Feb 20, 2023 at 15:56 | comment | added | Erik Eidt | DDD gives access to the whole aggregate via the root. In a simple implementation, reading the root order would return the entire aggregate, including all line items. | |
Feb 20, 2023 at 10:08 | comment | added | Álvaro García | When you tell the root can show child entities, do you mean it is correct if a consumer ask to the root entity for a child, the root entity can return the child that the consumer ask for? I mean, a consumer ask order for line 2, is correct the order return the line 2 to the consumer? The consumer will not can modify the line, because the line has not public methods to modify the line. The consumer will only can access data with readonly properties and get methods. If this is not correct, how could a consumer to know for example the price of a line? | |
Feb 16, 2023 at 16:59 | history | answered | Erik Eidt | CC BY-SA 4.0 |