|
From: =?iso-8859-1?Q?<jp....@ti...> - 2003-05-28 10:44:15
|
Hi Isabelle,=0D=0A=0D=0AWe are on the same wavelength, just a little "boo= boo" as you say:=0D=0Athe "element" elements were not closed in your exam= ple:=0D=0A <element refid=3D"alpha"/>=0D=0Ais what you probably would ty= pe. ;)=0D=0A=0D=0AJean-Pierre=0D=0A=0D=0A---------- Initial Header ------= -----=0D=0A=0D=0AFrom : spr...@li...= forge.net=0D=0ATo : rod...@in...=0D=0ACc = : spr...@li...=0D=0ADate : Wed, = 28 May 2003 12:32:42 +0200=0D=0ASubject : Re: [Springframework-developer]= Spring bean factory XML format=0D=0A=0D=0AHI Rod,=0D=0A=0D=0ADo it the w= ay JP suggested :=0D=0A=0D=0A<bean id=3D"foo">=0D=0A <property name=3D"mo= o">moo</property>=0D=0A <property name=3D"coll">=0D=0A <element refid=3D= "alpha">=0D=0A <element refid=3D"beta>=0D=0A </property>=0D=0A</bean>=0D= =0A=0D=0AIsabelle=0D=0A=0D=0AOn Wed, May 28, 2003 at 06:17:54AM -0400, ro= d.j...@in... wrote:=0D=0A> Isabelle, =0D=0A> =0D=0A> OK, we = can change name -> id when defining all beans, and use =0D=0A> refid for = references.=0D=0A> =0D=0A> The only problem I see with your syntax below.= ..=0D=0A> =0D=0A> <property name=3D"thefoo" refid=3D"foo/>=0D=0A> <proper= ty name=3D"moo">moo</property>=0D=0A> =0D=0A> ...is that I can't see how = it would support collections. I =0D=0A> see this as a major enhancement, = possible with the original =0D=0A> proposal, that had <value> and <ref> s= ubelements.=0D=0A> =0D=0A> I can easily change the XML parsing for whatev= er we agree. =0D=0A> =0D=0A> Regards,=0D=0A> Rod=0D=0A> =0D=0A> > Hi Rod,= =0D=0A> > =0D=0A> > There is one thing I do not like about your proposed = =0D=0A> syntax: you use <ref=0D=0A> > name=3D"xxx"> is used in two differ= ent contexts, one when you =0D=0A> define a bean=0D=0A> > that can serve = as a reference, and once when you refer to =0D=0A> such a bean from=0D=0A= > > another bean.=0D=0A> > That's confusing. It would be better to define= with for ex. =0D=0A> an id attribute,=0D=0A> > and reference with a refi= d attribute:=0D=0A> > =0D=0A> > <bean name=3D"foo" id=3D"foo"/>=0D=0A> > = <bean name=3D"bar" id=3D"bar">=0D=0A> > <property name=3D"thefoo" refid= =3D"foo/>=0D=0A> > <property name=3D"moo">moo</property>=0D=0A> > </bea= n>=0D=0A> > <bean name=3Dbaz>=0D=0A> > <property name=3D"bla">blabla</p= roperty>=0D=0A> > </bean>=0D=0A> > =0D=0A> > Note that bean bar can in tu= rn be referenced from other =0D=0A> beans, thanks to its=0D=0A> > id attr= ibute. Bean baz cannot be referenced, because it =0D=0A> doesn't have an = id=0D=0A> > attribute.=0D=0A> > =0D=0A> > A validating parser will not he= lp you make sure that bean =0D=0A> foo really exists=0D=0A> > when refere= nced, and neither will a DTD.=0D=0A> > =0D=0A> > Isabelle=0D=0A> =0D=0A> = =0D=0A> -------------------------------------------------------=0D=0A> Th= is SF.net email is sponsored by: ObjectStore.=0D=0A> If flattening out C+= + or Java code to make your application fit in a=0D=0A> relational databa= se is painful, don't do it! Check out ObjectStore.=0D=0A> Now part of Pro= gress Software. http://www.objectstore.net/sourceforge=0D=0A> ___________= ____________________________________=0D=0A> Springframework-developer mai= ling list=0D=0A> Spr...@li...=0D=0A> h= ttps://lists.sourceforge.net/lists/listinfo/springframework-developer=0D=0A= > =0D=0A> =0D=0A=0D=0A-- =0D=0AIsabelle Muszynski=0D=0ASoftware Engineer=0D= =0AZandweellaan 4=0D=0A2660 Antwerpen=0D=0ABelgium=0D=0ATel. 32-(0)3-830 = 18 54=0D=0AMobile: 32-(0)485 49 50 89=0D=0AEmail: isa...@me...= =0D=0AWebsite: www.meta-logix.com=0D=0A=0D=0A=0D=0A----------------------= ---------------------------------=0D=0AThis SF.net email is sponsored by:= ObjectStore.=0D=0AIf flattening out C++ or Java code to make your applic= ation fit in a=0D=0Arelational database is painful, don't do it! Check ou= t ObjectStore.=0D=0ANow part of Progress Software. http://www.objectstore= .net/sourceforge=0D=0A_______________________________________________=0D=0A= Springframework-developer mailing list=0D=0ASpringframework-developer@lis= ts.sourceforge.net=0D=0Ahttps://lists.sourceforge.net/lists/listinfo/spri= ngframework-developer=0D=0A=0A=0A********** SPECIAL ADSL **********=0AL'A= DSL =E0 partir de 15,95 EUR/mois et le modem ADSL offert ? C'est en excl= usivit=E9 chez Tiscali !=0APour profiter de cette offre, cliquez ici: htt= p://register.tiscali.fr/adsl/=0AOffre soumise =E0 conditions.=0A |