Re: [json-lib-user] Java 5
Brought to you by:
aalmiray
From: Andres A. <aal...@ya...> - 2008-03-24 22:11:40
|
Thanks Philippe, I will review the code, see how it can be added to the current build without breaking the jdk3 package. Cheers, Andres ------------------------------------------- http://jroller.com/aalmiray http://www.linkedin.com/in/aalmiray -- What goes up, must come down. Ask any system administrator. There are 10 types of people in the world: Those who understand binary, and those who don't. To understand recursion, we must first understand recursion. ----- Original Message ---- From: Philippe Kernevez <pke...@oc...> To: Andres Almiray <aal...@ya...>; jso...@li... Cc: André Nedelcoux <ane...@oc...>; Hub...@ca... Sent: Friday, March 21, 2008 4:41:21 AM Subject: RE: [json-lib-user] Java 5 <!-- _filtered {font-family:Tahoma;panose-1:2 11 6 4 3 5 4 4 2 4;} _filtered {font-family:"Comic Sans MS";panose-1:3 15 7 2 3 3 2 2 2 4;} _filtered {margin:72.0pt 90.0pt 72.0pt 90.0pt;} _filtered {} _filtered {} _filtered {font-family:Tahoma;panose-1:2 11 6 4 3 5 4 4 2 4;} /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {margin:0cm;margin-bottom:.0001pt;font-size:12.0pt;font-family:"Times New Roman";} a:link, span.MsoHyperlink {color:blue;text-decoration:underline;} a:visited, span.MsoHyperlinkFollowed {color:purple;text-decoration:underline;} p {margin-right:0cm;margin-left:0cm;font-size:12.0pt;font-family:"Times New Roman";} span.emailstyle17 {font-family:Arial;color:windowtext;} span.EmailStyle19 {font-family:Arial;color:navy;} _filtered {margin:72.0pt 90.0pt 72.0pt 90.0pt;} div.Section1 {} --> Hi, This is our JSON5Utils class. There is a lot of test with it, I expect that they will be enough for understand it. If you need help, ask for me. We are using this code for 2 weeks without any trouble. Regards, Philippe From: Andres Almiray[mailto:aal...@ya...] Sent: jeudi 6 mars 2008 20:56 To: Philippe Kernevez;jso...@li... Subject: Re: [json-lib-user] Java5 Hi Phllippe, As a matter of fact, generics support is one of the target features for ournext release, 2.3, so we would be very glad to review your patch and somehow accommodate the1.3/1.5 build we currently have. I'm not aware of a CVS->SVN url conversion, when I started the project I hadonly the choice for CVS repositories =-( Regards, Andres ------------------------------------------- http://jroller.com/aalmiray http://www.linkedin.com/in/aalmiray -- What goes up, must come down. Ask any system administrator. There are 10 types of people in the world: Those who understand binary, andthose who don't. To understand recursion, we must first understand recursion. ----- Original Message---- From: Philippe Kernevez <pke...@oc...> To: jso...@li... Sent: Thursday, March 6, 2008 8:42:31 AM Subject: [json-lib-user] Java 5 Hi, I am new to JSON-lib, may be my question is a newbie answer. I saw that there is a jdk15 version and Im using it. It seems that this version isnt really full jdk 5, is there some plan to have more java 5 compliant API? What do it mean? 1) A Generics API public class JSONObject { public static <T> T toBean( JSONObject jsonObject, Class<T> beanClass, Map classMap ) { } } 2) An automatic collection mapping based on Generics With such functionality, you example with EZMorph: http://json-lib.sourceforge.net/usage.html#From%20JSON%20to%20Beansin the From JSON to Beans will become: String json = "{'data':[{'name':'Wallace'},{'name':'Grommit'}]}"; MyBean bean = JSON5Utils.toBean( JSONObject.fromObject(json), MyBean.class, classMap ); Instead of String json = "{'data':[{'name':'Wallace'},{'name':'Grommit'}]}"; Map classMap = new HashMap(); classMap.put( "data", Person.class ); MyBean bean = (MyBean)JSONObject.toBean( JSONObject.fromObject(json), MyBean.class, classMap ); I already have code and tests for that functionalities, are you interesting by It and how do you want it (I cant give you a patch on you actual project, it only compiles with Java5) ? An independent Maven project? Another and independent question: is there an Svn connection URL instead of the cvs (I found the CVS one, but I cant succeed in converting it to standard sourceforge Svn url) ? Regards, Philippe Cemessage Envoi est certifié sans virus connu (AVG Pro). Analyse effectuée par AVG. Version: 7.5.516 / Base de données virus: 269.21.5/1314 - Date: 05/03/200818:38 -----Inline Attachment Follows----- ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ -----Inline Attachment Follows----- _______________________________________________ json-lib-user mailing list jso...@li... https://lists.sourceforge.net/lists/listinfo/json-lib-user Looking for last minute shopping deals? Find them fast with Yahoo! Search. Ce message Envoi est certifié sans virus connu (AVG Pro). Analyse effectuée par AVG. Version: 7.5.519 / Base de données virus: 269.21.8/1337 - Date: 20/03/2008 20:10 ____________________________________________________________________________________ Never miss a thing. Make Yahoo your home page. http://www.yahoo.com/r/hs |