Two Laptop Bag*
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes Page and Request Scope Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "Page and Request Scope" Watch "Page and Request Scope" New topic
Author

Page and Request Scope

Micheal John
Ranch Hand

Joined: Nov 01, 2006
Posts: 344
What is difference between page scope and request scope? can anyone give some example on ot?


Micheal John
SCJP 1.4 (86%), SCWCD 1.4 (86%), SCBCD 1.3 (85%), SCDJWS (Just Started...) - Satisfaction Lies in Our EFFORT, Not in the ATTAINMENT
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39578
    
  27
Request scope is wider than page scope. A request can consist of a page/servlet that is first accessed, and then of a number of "include" and "forward" resources. Those included or forwarded resources are part of the request, but not part of the (original) page scope. So one request can cause several pages to be accessed.

If no forwards or includes are happening during a request, then both scopes are identical.


Ping & DNS - updated with new look and Ping home screen widget
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Page and Request Scope
 
Similar Threads
Doubt Regarding implicit objects
page scope
Difference between request Scope and Page Scope?
jsp + thread safe
bean in or out scope?