javax.servlet Interfaces

Interfaces of the javax.servlet package include RequestDispatcher, Servlet, ServletConfig, ServletContext, ServletRequest, ServletResponse, and SingleThreadModel. Each is described in the following sections, along with its methods.

RequestDispatcher Interface

public interface RequestDispatcher

The RequestDispatcher interface defines an object, which can serve as a wrapper around another resource on the server. It is most often used to forward requests to other server resources. It defines two methods.

forward() Method
public void forward(ServletRequest request,
  ServletResponse response)
  throws ServletException,
  java.io.IOException

The forward() method is used for forwarding a request from one servlet to another. ...

Get Pure Java Server Pages™ now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.