Michael Hunger wrote:
> I also agree with Niclas. There is no point in restricting values to be 
> structs.
> The power of expressive values is not to be underestimated.

Agree.

> Regarding the possibilities of values and their equality perhaps we can take 
> some
> points from scala's case classes? Those embody the structure of their 
> creation and
> this information is also used for equals etc (was this other thing 
> constructed the
> same way as me).
> 
> (As a side note: This is also used for functional pattern matching and 
> accessing the
> construction time information.)

Right now I don't have any opinion on how to do this best, but Niclas' 
suggestion seemed logical enough for now.

> Regarding the persistence of values. If the type information take too much
> room we still can provide a custom serialization and have a lookup table for
> type information which is stored within the serializing store as well (saved 
> on update)
> and reloaded on startup.

Well, I have now actually changed this so that no type information is 
included. The upside of this is that the only place you have to look at 
for type information for a persisted Entity is the EntityType, which 
contains all the ValueType information, hierarchically. Otherwise there 
was a risk of duplication and uncertainty what was the real one.

/Rickard


_______________________________________________
qi4j-dev mailing list
[email protected]
http://lists.ops4j.org/mailman/listinfo/qi4j-dev

Reply via email to