yawda.controller
Class CController

java.lang.Object
  extended byjavax.servlet.GenericServlet
      extended byjavax.servlet.http.HttpServlet
          extended byyawda.controller.CController
All Implemented Interfaces:
Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig

public final class CController
extends javax.servlet.http.HttpServlet

Author:
Quentin Anciaux
See Also:
Serialized Form

Nested Class Summary
static class CController.CCache
           
static class CController.CHashtable
           
 
Field Summary
static String CONTROLLER_KEY
           
static int counter
           
static String DATE_FORMAT
           
static boolean DESTROYED
           
static Map mapCacheParams
           
static Map mapCacheURI
           
static int MAX_CACHE_TIME
           
static String YAWDA_CACHE_URI
           
 
Constructor Summary
CController()
           
 
Method Summary
static long _GetLastModified(javax.servlet.http.HttpServletRequest request)
           
static void cacheFile(javax.servlet.http.HttpServletRequest request, byte[] fBuffer)
           
static void cacheIt(String cache, String oType, boolean attach, String viewName, String oldFileName, javax.servlet.http.HttpServletRequest request)
           
protected static String CEnv(Object cenv, String paramName)
           
static boolean checkAndRender(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, ByteArrayOutputStream bOut)
           
static boolean checkLastModified(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
           
 void destroy()
           
protected static Object getCEnv(javax.servlet.http.HttpServletRequest request)
           
static String getURI(javax.servlet.http.HttpServletRequest request)
           
 void init(javax.servlet.ServletConfig config)
           
static void invalidateViews(String keyEnd)
           
static CController.CCache isInCache(javax.servlet.http.HttpServletRequest request)
           
protected  void service(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
           
static void setHeader(javax.servlet.http.HttpServletResponse response, long length, long lastModified, String etag)
           
 
Methods inherited from class javax.servlet.http.HttpServlet
doDelete, doGet, doHead, doOptions, doPost, doPut, doTrace, getLastModified, service
 
Methods inherited from class javax.servlet.GenericServlet
getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, log
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DESTROYED

public static boolean DESTROYED

counter

public static int counter

YAWDA_CACHE_URI

public static final String YAWDA_CACHE_URI
See Also:
Constant Field Values

mapCacheURI

public static Map mapCacheURI

mapCacheParams

public static Map mapCacheParams

CONTROLLER_KEY

public static final String CONTROLLER_KEY
See Also:
Constant Field Values

MAX_CACHE_TIME

public static final int MAX_CACHE_TIME
See Also:
Constant Field Values

DATE_FORMAT

public static final String DATE_FORMAT
See Also:
Constant Field Values
Constructor Detail

CController

public CController()
Method Detail

invalidateViews

public static final void invalidateViews(String keyEnd)

service

protected final void service(javax.servlet.http.HttpServletRequest request,
                             javax.servlet.http.HttpServletResponse response)
                      throws javax.servlet.ServletException,
                             IOException
Throws:
javax.servlet.ServletException
IOException

getURI

public static final String getURI(javax.servlet.http.HttpServletRequest request)

setHeader

public static final void setHeader(javax.servlet.http.HttpServletResponse response,
                                   long length,
                                   long lastModified,
                                   String etag)

destroy

public final void destroy()

init

public final void init(javax.servlet.ServletConfig config)
                throws javax.servlet.ServletException
Throws:
javax.servlet.ServletException

cacheFile

public static final void cacheFile(javax.servlet.http.HttpServletRequest request,
                                   byte[] fBuffer)
                            throws Exception
Throws:
Exception

cacheIt

public static final void cacheIt(String cache,
                                 String oType,
                                 boolean attach,
                                 String viewName,
                                 String oldFileName,
                                 javax.servlet.http.HttpServletRequest request)

CEnv

protected static final String CEnv(Object cenv,
                                   String paramName)

getCEnv

protected static final Object getCEnv(javax.servlet.http.HttpServletRequest request)

checkAndRender

public static final boolean checkAndRender(javax.servlet.http.HttpServletRequest request,
                                           javax.servlet.http.HttpServletResponse response,
                                           ByteArrayOutputStream bOut)
                                    throws Exception
Throws:
Exception

checkLastModified

public static final boolean checkLastModified(javax.servlet.http.HttpServletRequest request,
                                              javax.servlet.http.HttpServletResponse response)

_GetLastModified

public static final long _GetLastModified(javax.servlet.http.HttpServletRequest request)

isInCache

public static final CController.CCache isInCache(javax.servlet.http.HttpServletRequest request)