The only difference between
"fred"
and
new String("fred");
is that all occurances of the first one will be references to the same object, whereas
the second will generate unique objects everytime.
In most cases this makes no odds, but there are a few times where it might matter:
1) when using ==
2) when using synchronization.
Oh and the runtime will 'intern' the constant string.
URL: http://www.westpoint.ltd.uk/ - internet recon.
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html