jodd.madvoc
Class MadvocServletFilter

java.lang.Object
  extended by jodd.madvoc.MadvocServletFilter
All Implemented Interfaces:
javax.servlet.Filter

public class MadvocServletFilter
extends java.lang.Object
implements javax.servlet.Filter

Initializes and configures Madvoc and passes requests to MadvocController.


Field Summary
protected  javax.servlet.FilterConfig filterConfig
           
protected  MadvocConfig madvocConfig
           
protected  MadvocController madvocController
           
static java.lang.String PARAM_MADVOC_CONFIGURATOR
           
static java.lang.String PARAM_MADVOC_PARAMS
           
static java.lang.String PARAM_MADVOC_WEBAPP
           
protected  WebApplication webapp
           
 
Constructor Summary
MadvocServletFilter()
           
 
Method Summary
 void destroy()
          Filter destruction.
 void doFilter(javax.servlet.ServletRequest req, javax.servlet.ServletResponse res, javax.servlet.FilterChain chain)
          Builds ActionRequest and invokes it.
 void init(javax.servlet.FilterConfig filterConfig)
          Filter initialization.
protected  java.lang.String processUnhandledPath(java.lang.String actionPath, javax.servlet.ServletRequest request, javax.servlet.ServletResponse response)
          Process unconsumed action paths.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PARAM_MADVOC_WEBAPP

public static final java.lang.String PARAM_MADVOC_WEBAPP
See Also:
Constant Field Values

PARAM_MADVOC_CONFIGURATOR

public static final java.lang.String PARAM_MADVOC_CONFIGURATOR
See Also:
Constant Field Values

PARAM_MADVOC_PARAMS

public static final java.lang.String PARAM_MADVOC_PARAMS
See Also:
Constant Field Values

filterConfig

protected javax.servlet.FilterConfig filterConfig

webapp

protected WebApplication webapp

madvocConfig

protected MadvocConfig madvocConfig

madvocController

protected MadvocController madvocController
Constructor Detail

MadvocServletFilter

public MadvocServletFilter()
Method Detail

init

public void init(javax.servlet.FilterConfig filterConfig)
          throws javax.servlet.ServletException
Filter initialization.

Specified by:
init in interface javax.servlet.Filter
Throws:
javax.servlet.ServletException

destroy

public void destroy()
Filter destruction.

Specified by:
destroy in interface javax.servlet.Filter

doFilter

public void doFilter(javax.servlet.ServletRequest req,
                     javax.servlet.ServletResponse res,
                     javax.servlet.FilterChain chain)
              throws java.io.IOException,
                     javax.servlet.ServletException
Builds ActionRequest and invokes it. If action result is a chain, it repeats the process.

Specified by:
doFilter in interface javax.servlet.Filter
Throws:
java.io.IOException
javax.servlet.ServletException

processUnhandledPath

protected java.lang.String processUnhandledPath(java.lang.String actionPath,
                                                javax.servlet.ServletRequest request,
                                                javax.servlet.ServletResponse response)
                                         throws java.io.IOException,
                                                javax.servlet.ServletException
Process unconsumed action paths. Returns null if action path is consumed, otherwise it returns action path to be consumed by filter chain. By default it just returns action path.

Throws:
java.io.IOException
javax.servlet.ServletException


Copyright © 2003-2010 Jodd Team