What is a Filter in JSP ?

We can define filters in JSP to intercept requests from a client or to change response from a server.

Filter is a Java class that is defined in the deployment descriptor of web.xml of an application. The JSP container reads filter from web.xml and applies a filter as per the URL pattern associated with the filter.

JSP Engine loads all the filters in when we start the server.



You May Interest

How Will You Make an Object Immutable in Java ?

What is the Difference Between pass by reference and pass by valu ...

What is the Different Type of Tag Library Groups in JSTL ?

Why Collection Interface Doesn’t Extend Cloneable and Serializabl ...

What is a Singleton Class in Java ?