I have studied the CaveatEmptor Native example and most things are clear to me.
But I don't understand one thing.
In the Category.hbm.xml, the list with items has a <list-index column="DISPLAY_POSITION"/>, that matches the column DISPLAY_POSITION in the CATEGORY_ITEM table.
I think this orders the items in the List in the Category Object.
But where is this property set in the Java Object??, because the Item Object has no ordering property (displayPosition).
When I add a new Item in a Category, what sets the DISPLAY_POSITION in the CATEGORY_ITEM table??
I want the possibility to change the order of my items. Therefore the Items need some kind of order property.
How can I achieve this?
|