Class FilterDef

  • All Implemented Interfaces:
    Serializable
    Direct Known Subclasses:
    FilterDefDecorator

    public class FilterDef
    extends Object
    implements Serializable
    Representation of a filter definition for a web application, as represented in a <filter> element in the deployment descriptor.
    Version:
    $Revision: 1.3.6.1 $ $Date: 2008/04/17 18:37:10 $
    Author:
    Craig R. McClanahan
    See Also:
    Serialized Form
    • Constructor Detail

      • FilterDef

        public FilterDef()
    • Method Detail

      • getDescription

        public String getDescription()
      • setDescription

        public void setDescription​(String description)
      • getDisplayName

        public String getDisplayName()
      • setDisplayName

        public void setDisplayName​(String displayName)
      • getFilterClassName

        public String getFilterClassName()
      • setFilterClassName

        public void setFilterClassName​(String filterClassName)
      • getFilterClass

        public Class<? extends jakarta.servlet.Filter> getFilterClass()
      • setFilterClass

        public void setFilterClass​(Class<? extends jakarta.servlet.Filter> filterClass)
      • getFilter

        public jakarta.servlet.Filter getFilter()
      • setFilter

        public void setFilter​(jakarta.servlet.Filter filter)
      • getFilterName

        public String getFilterName()
      • setFilterName

        public void setFilterName​(String filterName)
      • getLargeIcon

        public String getLargeIcon()
      • setLargeIcon

        public void setLargeIcon​(String largeIcon)
      • getSmallIcon

        public String getSmallIcon()
      • setSmallIcon

        public void setSmallIcon​(String smallIcon)
      • setIsAsyncSupported

        public void setIsAsyncSupported​(boolean isAsyncSupported)
        Configures this filter as either supporting or not supporting asynchronous operations.
        Parameters:
        isAsyncSupported - true if this filter supports asynchronous operations, false otherwise
      • isAsyncSupported

        public boolean isAsyncSupported()
        Checks if this filter has been annotated or flagged in the deployment descriptor as being able to support asynchronous operations.
        Returns:
        true if this filter supports async operations, and false otherwise
      • addInitParameter

        public void addInitParameter​(String name,
                                     String value)
        Adds the initialization parameter with the given name and value on this filter.

        If an init param with the given name already exists, its value will be overridden.

        Parameters:
        name - the init parameter name
        value - the init parameter value
      • setInitParameter

        public boolean setInitParameter​(String name,
                                        String value,
                                        boolean override)
        Sets the init parameter with the given name and value on this filter.
        Parameters:
        name - the init parameter name
        value - the init parameter value
        override - true if the given init param is supposed to override an existing init param with the same name, and false otherwise
        Returns:
        true if the init parameter with the given name and value was set, false otherwise
      • setInitParameters

        public Set<String> setInitParameters​(Map<String,​String> initParameters)
        Sets the initialization parameters contained in the given map on this filter.
        Parameters:
        initParameters - the map with the init params to set
        Returns:
        the (possibly empty) Set of initialization parameter names that are in conflict
      • getInitParameter

        public String getInitParameter​(String name)
      • removeInitParameter

        public void removeInitParameter​(String name)
        Removes the initialization parameter with the given name.
        Parameters:
        name - the name of the initialization parameter to be removed
      • toString

        public String toString()
        Render a String representation of this object.
        Overrides:
        toString in class Object