Refresh Your Java - Before Java Interview
We are Agile, believe in less Documentation - Only Quick notes (Java Interview Questions) of Java/J2ee Read more....
Yes HTTP is stateless, meaning every request is
being treated as a new one and
state (data) will not be
shared between two http requests, but Servlet
API
provide the some mechanisms address this issue. Below
are Servlet
state management techniques.
i) Use POST/GET variables to pass info from page to
page. (Hidden Variables)
<input
type='hidden'
name='userName'>
request.getParameter
('userName');
ii) Use the
session to store information.
session.setAttribute("userName",
"testUser");
value =
session.getAttribute("userName");
iii) Use cookies to store information.
Cookie
cookie = new Cookie("CName","Cookie
Value");
cookie.setMaxAge(100);
response.addCookie(cookie);
This Portal is intended to put all Java/J2ee related topics at one single place for quick referance, not only Technical , but also the Project Management Related thing such as Development Process methodoogies build process, unit testing etc.,
This Portal has More than 500 Java Interview Questions (also could be Considered as Quick Notes) very neatly separated topic by topic with simple diagrams which makes you easily understandable. Importantly these are from our Realtime expericance.