KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > genimen > djeneric > web > DjenericDispatcher


1 package com.genimen.djeneric.web;
2
3 import java.io.IOException JavaDoc;
4
5 import javax.servlet.ServletConfig JavaDoc;
6 import javax.servlet.ServletException JavaDoc;
7 import javax.servlet.http.HttpServletRequest JavaDoc;
8 import javax.servlet.http.HttpServletResponse JavaDoc;
9
10 import com.genimen.djeneric.web.controller.DjenericController;
11 import com.genimen.djeneric.web.util.DjenericServlet;
12
13 /**
14  * @author Wido Riezebos
15  */

16
17 public class DjenericDispatcher extends DjenericServlet
18 {
19   private static final long serialVersionUID = 1L;
20
21   private DjenericController _controller;
22
23   public void init(ServletConfig JavaDoc config) throws ServletException JavaDoc
24   {
25     super.init(config);
26
27     _controller = new DjenericController(config.getServletContext());
28   }
29
30   protected void service(HttpServletRequest JavaDoc request, HttpServletResponse JavaDoc response) throws ServletException JavaDoc, IOException JavaDoc
31   {
32     disableBrowserCaching(response);
33     _controller.handleRequest(request, response);
34   }
35
36 }
Popular Tags