Home Tutorial Jsp Page Directive attribute - extends

 
 

Page Directive attribute - extends
Posted on: November 30, 2012 at 12:00 AM
Advertisement
This tutorial contains description of extends attribute of page Directive.

Page Directive attribute - extends

This tutorial  contains description of extends attribute of page Directive.

extends Attribute :

This attribute specifies the super class of the JSP page's implementation servlet. It allows you to inherit a class that is super class of the class created by runtime compiling this JSP page. It is rarely used.

Syntax :

<%@ page extends="package.class" %>

Example :

By default HttpJspBase is the super class in translated servlet in Tomcat. Suppose you want another super class in place of HttpJspBase then use extends.
 

<%@page language="java" extends="javax.servlet.http.HttpServlet"%>
Advertisement

Related Tags for Page Directive attribute - extends:


Follow us on Twitter, or add us on Facebook or Google Plus to keep you updated with the recent trends of Java and other open source platforms.

Posted on: November 30, 2012

Recommend the tutorial

Advertisements Advertisements
 

 

 

DMCA.com