explain filters in java?
Answers were Sorted based on User's Feedback
Answer / srikanth
filters are used to preprocessing and postprocessing of
tasks like login,authorization,data compression,data
encoding etc
for this u need to override intit(),dofilter(),and destroy()
| Is This Answer Correct ? | 16 Yes | 0 No |
Answer / suresh royal
Filter is a special web resource program that is capable of
trapping the request and taking the response of other web
resource programs.
Filter is a interface .
A servlet program which is implemented javax.servlet.Filter
interface is called "Servlet Filter"
Filter having three methods..
==================================
init(FilterConfig fg)
DoFilter(SReq req ,Sres res,FilterChain fc)
destroy()
| Is This Answer Correct ? | 7 Yes | 0 No |
How many objects of a servlet is created?
What methods do you use in servlet - applet communication?
The code in a finally clause will never fail to execute, right?
what is the difference between Servlet and JSP?Advantage of JSP over Servelt?Any concept present in JSP which we cant implement in Servlet?
31 Answers ABC, Apere, AZTEC, CTS, CybAge, iFlex, Impact Systems, Sara, TCS,
What are the advantages of Servlet over CGI?
how the HTML data stored in web server?
What is the difference between portlet and servlet?
What is the difference between 2 types of servlets?
What is servlet name in web xml?
What are the types of ServletEngines?
Is the init(ServletConfig sc) throws IOException or not?
Write a hello world program using servlets.