I browsed the book and the reference, but cant find a way out (besides perhaps creating a UserType like in pg 203, which i'm not ready for now).
Suppose user wants to store her collection of favorite players, from a given choice.
Also he wants to store injured players apart.
So, i build class Player, with id, name, accessors. From my view point i need two sets:
Set myPlayers = new HashSet;
Set injuredPlayers = new HashSet;
My problem: how can i persist this second Set?
If i try to store injuredPlayer as String all is fine, but if i try to store it as Player - therefore creating a InjuriedPlayer class, i get a configuring error because "Player" isnt a recognized type!!
But when i persist myPlayers to Player class everything goes fine.
It seems i cant find a solution to this, anywhere in book or reference.
So, how can i store Player type objects in two (or more) diferent Set?
thanks in advance
|