JSP Scopes: JSP provides very useful features. One of them is maintaining the user defined variable. As you all know that in JAVA, each variable has a scope. Scope decides the accessibility of an object or variable. For example, some variables are accessible within for loop, if-else block or within specific method or class or package.
Same way, in JSP some variables needs to have different scopes than others. JSP provides the capability to user to define the scope of these variables.
Type of Scopes in JSP: JSP provides 4 scopes to a variable. Developer can assign any one of them to a variable.
1. Page Scope.
2. Request Scope.
3. Session Scope.
4. Application Scope.
We will see each of these scopes in details with examples in next tutorials.