Class WebtoolkitFilter

  • All Implemented Interfaces:
    javax.servlet.Filter
    Direct Known Subclasses:
    TransportWebtoolkitFilter

    public abstract class WebtoolkitFilter
    extends Object
    implements javax.servlet.Filter
    Manages requests to the JWT core. Consumes and serves only JWT related requests, other requests will not be touched.

    This class that serves as a base class for the Filter implementations in JWT's server side connection implementations. It is recommended to register any specific WebtoolkitFilter implementation using either the pattern /* or /MODULE_NAME/*.

    • Constructor Detail

      • WebtoolkitFilter

        public WebtoolkitFilter()
    • Method Detail

      • init

        public void init​(javax.servlet.FilterConfig config)
                  throws javax.servlet.ServletException
        Specified by:
        init in interface javax.servlet.Filter
        Throws:
        javax.servlet.ServletException
      • configureServlets

        protected abstract void configureServlets​(javax.servlet.FilterConfig config,
                                                  com.levigo.jadice.web.server.internal.JWTServerContext serviceProvider)
                                           throws javax.servlet.ServletException
        Add your servlets here.
        Parameters:
        config -
        serviceProvider -
        Throws:
        javax.servlet.ServletException
      • destroy

        public final void destroy()
        Specified by:
        destroy in interface javax.servlet.Filter
      • doDestroy

        protected void doDestroy()
      • doFilter

        public void doFilter​(javax.servlet.ServletRequest servletRequest,
                             javax.servlet.ServletResponse response,
                             javax.servlet.FilterChain filterChain)
                      throws IOException,
                             javax.servlet.ServletException
        Specified by:
        doFilter in interface javax.servlet.Filter
        Throws:
        IOException
        javax.servlet.ServletException