commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stephen Colebourne" <scolebou...@btopenworld.com>
Subject Re: [beanutils] Generifying the Converter interface
Date Thu, 14 Oct 2004 21:57:28 GMT
FYI, there is a sandbox project [convert] that I tried to setup to be a
dedicted converter project. I ran out of time, so it never got completed,
but you may want to take a look.

Note that JDK1.5 compilation is going to cause issues to commons in general.

Stephen

----- Original Message -----
From: "Kris Nuttycombe" <Kris.Nuttycombe@noaa.gov>
> I'm just starting to play around with generics, and thought that
> org.apache.commons.beanutils.Converter might be an interesting candidate
> for generification. A good generified converter library is broadly
> useful outside of BeanUtils.
>
> Here's my first thought on generifying the Converter interface:
>
> public interface Converter<I,O>{
>     /**
>      * Convert the specified input object into an output object of the
>      * specified type.
>      *
>      * @param type Data type to which this value should be converted
>      * @param value The input value to be converted
>      *
>      * @exception ConversionException if conversion cannot be performed
>      *  successfully
>      */
>     public O convert(Class<O> type, I value);
> }
>
> Comments, suggestions?
>
> Kris
>
> --
> =====================================================
> Kris Nuttycombe
> Associate Scientist
> Geospatial Data Services Group
> CIRES, National Geophysical Data Center/NOAA
> (303) 497-6337
> Kris.Nuttycombe@noaa.gov
> =====================================================
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-dev-help@jakarta.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message