tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tobias Eriksson" <tobias.eriks...@comopt.com>
Subject how do I call a function in a bean the easy an tidy way?
Date Tue, 17 Aug 2004 11:46:34 GMT
Hi
 I'm trying to call a method in a BEAN that returns an array of objects
that I need to enumerate on my page. But I don't want to access a
property with EL, like this e.g. ${mybean.names} ) as I need to provide
an argument to the method. I need to say how many names I would like, so
the only thing I could come up with was this;

<c:set var="names" value="<%= mybean.getNames( Integer.parseInt(
request.getParameter("total") )  ) %>" />

Now this looks a bit cumbersome and I was thinking if anyone knew of a
better way of doing this. For example 
	${ mybean.getNames(request.getParameter("total") ) }
would have been nicer and tidier. 

Regards
 Tobias

-----Original Message-----
From: Andy Eastham [mailto:andy@peakdrive.com] 
Sent: Tuesday, August 17, 2004 10:11
To: 'Tomcat Users List'; krawietz@hrs.de
Subject: RE: understanding web.xml

Also look at the sample chapter at http://www.moreservlets.com/

Andy

> -----Original Message-----
> From: Thilo Krawietz [mailto:thilo.krawietz@hrs.de]
> Sent: 17 August 2004 08:07
> To: Tomcat Users List
> Subject: Re: understanding web.xml
> 
> Hi Tobias,
> 
> in Suns official Servlet specification all elements of web.xml are
> explained widely, so i would suggest, that you study this one. You can
> get it here:
> 
> http://java.sun.com/products/servlet/download.html
> 
> Hope this helps & regards,
> 
> Thilo
> 
> 
> Tobias Eriksson wrote:
> 
> >Hi
> > I have been searching the web some for information about how to
> >configure / setup; web.xml, but haven't really found anything. I
thought
> >there would be something in the TOMCAT documentation, perhaps I
wasn't
> >to thorough when I browsed through it. Does anyone have a link to
some
> >tutorial or article that explains the web.xml?
> >
> >Regards
> > Tobias
> >
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> >For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >
> >
> >
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org



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



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


Mime
View raw message