|
From: Rod J. <rod...@in...> - 2003-05-30 10:37:56
|
JP, I like this. It's an improvement. We could even support object keys by having a <key> subelement that supports a<value> or ref. But that's in the future. Isabelle wrote "I like the collections idea, but not the different keywords for it (map, collection). All the user has to know is that it's a collection, not how we implment it internally." (I don't think you sent this to the list.) But aren't maps different to collections or arrays (which we might also want to support eventually?) Two values to manage, not just one? I'm inclined to support Maps like this in 0.8. Regards, Rod ----- Original Message ----- From: "JP Pawlak" <jp....@ti...> To: <rod...@in...> Cc: <spr...@li...> Sent: Friday, May 30, 2003 11:05 AM Subject: RE : RE : [Springframework-developer] DTD Rod, I'm inclined too to favor this. But I see another improvement without having now the right solution about the map. In UrlHandlerMapping the data is in fact a bean reference and this is not already checked. In methodNameResolver in contrast, it's a simple text (method name). Perhaps will we have an unique value/ref in the map entry body instead of simple text? <property name="mappings"> <map> <entry key="/welcome.html"><ref bean="pagedListController"/></entry> <entry key="/detail.html"><ref bean="pagedListController"/></entry> </map> </property> <property name="mappings"> <map> <entry key="/welcome.html"><value>showMain</value></entry> <entry key="/detail.html"><value>showDetail</value></entry> </map> </property> Regards, Jean-Pierre > -----Message d'origine----- > De : rod...@in... [mailto:rod...@in...] > Envoyé : vendredi 30 mai 2003 11:24 > À : JP Pawlak > Cc : 'Rod Johnson'; spr...@li... > Objet : Re: RE : [Springframework-developer] DTD > > > JP, > > I agree, formalizing map support would be an improvement. I'm > not sure we can do it for 0.8, though. Presently it's handled > by a PropertyEditor. > > I wonder if it means we should introduce additional container > elements <list> and <map> into our DTD? e.g.: > > <property name="simple"><value>val</value></property> > <property name="mappings"> > <map> > <entry key="/welcome.html">pagedListController</entry> > <entry key="/detail.html">pagedListController</entry> > </map> > </property> > > <property name="coll"> > <collection> > <value>val</value> > <ref bean="foo"/> > </collection> > </property> > > It's getting still more verbose, but it would be easier to > parse and is more elegant. (Don't need to guess whether a > value/ref is part of a collection.) > > I'm inclined to favour this. I could probably implement it by > early next week (including maps). > > Regards, > Rod > |