Class NanoFilterConfig

java.lang.Object
cloud.piranha.nano.NanoFilterConfig
All Implemented Interfaces:
FilterConfig

class NanoFilterConfig
extends java.lang.Object
implements FilterConfig
The FilterConfig class used by NanoPiranhaBuilder so it can initialize a Filter.
Author:
Manfred Riem (mriem@manorrock.com)
See Also:
cloud.piranha.nano
  • Field Summary

    Fields
    Modifier and Type Field Description
    private java.lang.String filterName
    Stores the filter name.
    private java.util.HashMap<java.lang.String,​java.lang.String> initParameters
    Stores the init parameters.
    private ServletContext servletContext
    Stores the servlet context.
  • Constructor Summary

    Constructors
    Constructor Description
    NanoFilterConfig​(ServletContext servletContext)
    Constructor.
  • Method Summary

    Modifier and Type Method Description
    java.lang.String getFilterName()
    Get the filter name.
    java.lang.String getInitParameter​(java.lang.String name)
    Get the init parameter.
    java.util.Enumeration<java.lang.String> getInitParameterNames()
    Get the init parameter names.
    ServletContext getServletContext()
    Get the servlet context.
    void setFilterName​(java.lang.String filterName)
    Set the filter name.
    void setInitParameter​(java.lang.String name, java.lang.String value)
    Set the init parameter.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • filterName

      private java.lang.String filterName
      Stores the filter name.
    • initParameters

      private final java.util.HashMap<java.lang.String,​java.lang.String> initParameters
      Stores the init parameters.
    • servletContext

      private final ServletContext servletContext
      Stores the servlet context.
  • Constructor Details

    • NanoFilterConfig

      public NanoFilterConfig​(ServletContext servletContext)
      Constructor.
      Parameters:
      servletContext - the servlet context.
  • Method Details

    • getInitParameter

      public java.lang.String getInitParameter​(java.lang.String name)
      Get the init parameter.
      Specified by:
      getInitParameter in interface FilterConfig
      Parameters:
      name - the name.
      Returns:
      the value, or null if not found.
    • getInitParameterNames

      public java.util.Enumeration<java.lang.String> getInitParameterNames()
      Get the init parameter names.
      Specified by:
      getInitParameterNames in interface FilterConfig
      Returns:
      the init parameter names.
    • getServletContext

      public ServletContext getServletContext()
      Get the servlet context.
      Specified by:
      getServletContext in interface FilterConfig
      Returns:
      the servlet context.
    • getFilterName

      public java.lang.String getFilterName()
      Get the filter name.
      Specified by:
      getFilterName in interface FilterConfig
      Returns:
      the filter name.
    • setFilterName

      public void setFilterName​(java.lang.String filterName)
      Set the filter name.
      Parameters:
      filterName - the filter name.
    • setInitParameter

      public void setInitParameter​(java.lang.String name, java.lang.String value)
      Set the init parameter.
      Parameters:
      name - the name.
      value - the value.