how JSP can extend servlet or interface ...?

Answer Posted / jayakrishna

We cannot implement an interface in a jsp but we can extend
a class in JSP by using extends attribute of the page
directive.

extends "package.class"
The fully qualified name of the superclass of the Java
class file this JSP file will be compiled to. Use this
attribute cautiously as it can limit the JSP container's
ability to provide a specialized superclass that improves
the quality of the compiled file.


Is This Answer Correct ?    7 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain the servlet filter.

540


How do we translate jsp?

578


Explain the role of dispatcherservlet and contextloaderlistener.

608


Why are http servlets used in programming?

546


What is a servlet context?

601






What are the uses of servlet and what is servlet chaining?

559


If some new data has entered the database, explain how can a servlet refresh automatically?

739


How the typical servlet code look like ?

636


Write a command to get actual path of a servlet to the server?

541


What are all the protocols supported by httpservlet?

651


explain the advantages of servlet life cycle?

560


Is java servlet still used?

590


What's the use of servletcontext?

683


What are the life cycle methods of the servlet?

578


What is servlet api used for conneting database?

700