Details
-
Type:
Improvement
-
Status:
Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: 1.0.0
-
Component/s: DSL for Business Domain
-
Labels:None
-
Number of attachments :
Description
For ordered associations the following method are generated:
- addTo***(element)
- removeFrom***(element)
To be able to use the ordering in a meaningful way the following method need to be generate as well:
- addTo***(index, element)
- removeFrom***(index)
- set(index, element)
These match the methods in the Java List interface.
Issue Links
| This issue depends upon: | ||||
| MODFORJ-31 | equals method in domain objects |
|
|
|
Without an 'equals()' method that can compare objects by the persistent 'id' property, you can only remove an element from an ordered collection if it is the same object.
With an 'equals()' method that compares by 'id', if the objects are not the same, you can also remove elements if there were retrieved in a different Hibernate transaction (and session).