You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by "Porter, Roy" <ro...@uk.fid-intl.com> on 2002/02/22 15:14:59 UTC

[BeanUtils] Converter, copyProperties

I've just been developing my own 'copyProperties' to copy properties from a
normal Javabean to a Dynabean, and vice versa.

I originally looked at implementing the Converter interface, but ended up
not doing for the simple reason that 
my destination bean may already exist, and I don't necessarily want the
expense of creating a new one. 

It would be ideal if there was also a convert(Object, Object) method. They
could of course use the same underlying code .....

Is the Converter interface specifically for use within the Beanutils
package, or is it intended for people to pick up and use elsewhere ? 

Another query is when converting Locale dependant information (particularly
in my instance, dates) there's no way to pass in the locale. 

So I guess I'm suggesting something like :

convert(Class, Object);

convert(Object, Object);

convert(Class, Object, Locale);

convert(Object, Object, Locale);


or should I just forget about using the Converter interface ?


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>