velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ted Husted <hus...@apache.org>
Subject Re: Velocity + Database
Date Thu, 07 Aug 2003 15:33:32 GMT
Tim Colson wrote:
> I've taken another [hack] approach lately and added a
> getViewableHashMap() method to my biz entities. This method places the
> objects data into a flat hashmap for the preso layer. This also enables
> the flattening to Person.AddressStreet, but it breaks down for nested
> collections. Ex. if Person contains a collection of addresses and we
> call Person.getViewableHashmap() -> do we expect the data from just
> Person, or also the list of addresses? And then if an Address contains a
> recursive Person object, we must prevent going infinitely deep.

Which are *exactly* the same sort of problems we have to address with 
ORM packages -- except in the other direction.

So, something I keep thinking about is a tool that worked like the 
Hibernate session but let me map a rich object to a flat transfer 
object, and vice versa. It wouldn't surprise me to find one out there, 
it's just that the Java Universe is *so* huge now =;0)

-Ted.



Mime
View raw message