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 how many instances of java bean in jsp? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Servlets
Reply Bookmark "how many instances of java bean in jsp?" Watch "how many instances of java bean in jsp?" New topic
Author

how many instances of java bean in jsp?

hanumanth reddy
Ranch Hand

Joined: Jun 12, 2000
Posts: 118

Hi,

If a jsp pages is accessing javabean then how many instance of that class are created ?


<a href="http://www.jobklub.com" target="_blank" rel="nofollow">http://www.jobklub.com</a><br /> 'Add Job To Life'
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 11862
That depends on the scope of the Bean as declared in the scope attribute of the <jsp:useBean tag.
page or request = one instance per call (default)
session = one instance per session
application = one instance shared by entire web application
Bill

------------------
author of:


Java Resources at www.wbrogden.com
 
 
subject: how many instances of java bean in jsp?
 
Threads others viewed
Standard Action Tags
basic question
JSP API
How many session object created in a single jsp page?
Servlet & JSP: A Tutorial Does the world need another?
developer file tools