Hello Milt!

ME> On Tue, 29 Jan 2002, Christopher K. St. John wrote:

>> Anton Tagunov wrote:
>> >
>> > out.write("<html>");
>> > generally results in the string being sent right to the user via
>> > the underlying socket implementation without any memory allocation.
>> >
>>
>>  Premature optimization is the root of all evil :-)

ME> Besides, doesn't using a string literal like "<html>" actually create
ME> an object in Java?  (Meaning that it does use some memory.)

Yes it does but exactly one. Every time the code runs a reference to
the same String object is used. The object is "created" at the time
the class is being loaded and not recreated at each code run :-)

- Anton
[EMAIL PROTECTED]
[EMAIL PROTECTED]

___________________________________________________________________________
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

Reply via email to