File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Servlets and the fly likes javabean question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "javabean question" Watch "javabean question" New topic
Author

javabean question

Yongping Wang
Ranch Hand

Joined: May 15, 2001
Posts: 40
Hi, All:
I have a question about javabean use. Here is the situation:
I initialize a javabean in a jsp page like <jsp useBean id="book" class=BookInfo" scope="session">
What will happen if I put an object (named book) of BookInfo into a session using session.setAttribute("book", book) in a servlet then the servlet forwards to the above jsp page?
1. two different objects of book coexist
2. the object of book initialized in the jsp page replace the object of book stored in session created in a servlet
3. the object of book initialized in the jsp page is the same as stored in session created in servlet. so the former has all infomation associated with the latter
Please clarify it for me. Thanks a lot.
Yongping
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: javabean question