I was looking at that possibility, but, if doing so, my own tag should redefine all setter property for the original tags: the html:select tag, for example has a style attribute; If I use it as a private object inside mine, I have to redefine the getStyle and setStyle methods; this of course is still valid for all other attributes.
It is maybe better to extend one of the tags i want to use, and then add code, as suggested by Nicolas... What I don't like in this solution is I don't really reuse code (In the Nicolas example, code from SelectTag is reused, but for writing a Submit button I have to copy, or write my own code ...) ____________________________________ Renato Romano Sistemi e Telematica S.p.A. Calata Grazie - Vial Al Molo Giano 16127 - GENOVA e-mail: [EMAIL PROTECTED] Tel.: 010 2712603 _____________________________________ -----Original Message----- From: Noureddine Bekrar [mailto:[EMAIL PROTECTED] Sent: venerd� 14 marzo 2003 16.06 To: Struts Users Mailing List; [EMAIL PROTECTED] Subject: Re: Tag Extension exactely ----- Original Message ----- From: "Renato Romano" <[EMAIL PROTECTED]> To: "'Noureddine Bekrar'" <[EMAIL PROTECTED]>; "'Struts Users Mailing List'" <[EMAIL PROTECTED]> Sent: Friday, March 14, 2003 4:10 PM Subject: RE: Tag Extension > You mean something like: ?? > > Public class SelectPlusButton extends TagSupport > { > > > doStartTag(...) > { > // Write out a table definition... > SelectTag st = new SelectTag(); > st.doStartTag(..); > ... > ButtonTag bt = new ButtonTag(); > bt.doStartTag(); > .... > } > } > > ____________________________________ > Renato Romano > Sistemi e Telematica S.p.A. > Calata Grazie - Vial Al Molo Giano > 16127 - GENOVA > > e-mail: [EMAIL PROTECTED] > Tel.: 010 2712603 > _____________________________________ > > > -----Original Message----- > From: Noureddine Bekrar [mailto:[EMAIL PROTECTED] > Sent: venerd� 14 marzo 2003 15.52 > To: Struts Users Mailing List; [EMAIL PROTECTED] > Subject: Re: Tag Extension > > > i think to do that , you must write a new tag java class (extends > "TagSupport" class)and in this class you will use a java code of the 2 > other classes ( select and option). > > and after this you will declare your new tag in the tld file. > > ----- Original Message ----- > From: "Renato Romano" <[EMAIL PROTECTED]> > To: "'Struts Users Mailing List'" <[EMAIL PROTECTED]> > Sent: Friday, March 14, 2003 3:24 PM > Subject: Tag Extension > > > > What is the standard way to "extend" a struts tag, or generally > > whatever jsp tag ? Do I have to extend the Java class Implementing > > that tag ? To be more clear: in my application I have to often use a > > select/options struts tag, together with a button, so it would be > > useful in the jsp page to only use one construct. Any ideas ? Thanks > > a lot. > > > > Renato > > > > P.S.: I know, this is not really a struts question, but I think it > > would be of interest ... > > > > ____________________________________ > > Renato Romano > > Sistemi e Telematica S.p.A. > > Calata Grazie - Vial Al Molo Giano > > 16127 - GENOVA > > > > e-mail: [EMAIL PROTECTED] > > Tel.: 010 2712603 > > _____________________________________ > > > > > > > > -------------------------------------------------------------------- > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

