On Monday 18 Mar 2002 18:41 pm, you wrote:
> Just don't...  ;-)
>
> Good Java style dictates that you keep everything as private as possible,
> certainly class variables and then use methods to get and set them, like
> getY and setY.

Yes, I understand good Java style (having done it for so long), however 
public static variables are common place and useful. I wouldn't ever want to 
provide get methods for these as it's clearly evil ;-) 

For example, I have a servlet that takes two parameters, A and B. I don't 
want to do:

moo?a=Whatever&b=whatever, 

as I might, one day, want to change the names of the parameters of A and B. 
Therefore I use public statics in the servlet to store the names of these 
attributes. Ie:

moo?<%= MyServlet.A %>=Whatever

*much* nicer when you're writing generic components.

However it looks like I have no choice :(

That's a real minus point for JSTL.


John

-- 
John Baker, BSc CS.
Java Developer, TEAM Slb. (http://www.teamenergy.com/)
The views expressed in this mail are my own.

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to