Yeah, something like that. Also Cayenne's own object access since 3.0 is fully based on pluggable ClassDescriptors, so declaring read/ writeProperty on the object is not needed for Cayenne, and technically only the generic objects need such user-facing methods.

Andrus


On Nov 19, 2009, at 12:26 PM, Andrey Razumovsky wrote:

So you suggest to use simple fields as properties? Makes sense. We could stay in same DataObject interface as now. Then read/writeProperty methods
would work through reflection.. I agree this will make classes more
POJO-like

2009/11/19 Andrus Adamchik <[email protected]>

Actually with Hessian it may be only marginally larger with HashMap (IIRC
how it does map serialization). With Java serialization it will be
significantly larger, as it likely serializes all the hash bucket structure.

In any event, like I said in another thread, if we are to reconcile the object structures between ROP and regular Cayenne, I'd rather we move closer to POJO instead of away from it (with important exception being support for generic objects). POJO's take less memory, have no threading issues and are
generally easier to understand by the users.

Andrus



On Nov 19, 2009, at 11:10 AM, Andrey Razumovsky wrote:

We wanted lighter POJO on the client.


Are you sure serialization speed/size for Hessian/java serialization
will be
better for class with 10 attributes than class with one HashMap attribute,
*probably* containing those attributes? (and why?)





--
Andrey

Reply via email to