Class FilterSet

  • All Implemented Interfaces:
    Filter

    public class FilterSet
    extends java.lang.Object
    implements Filter
    A filter set applies filters to AuditEvents. If a filter in the set rejects an AuditEvent, then the AuditEvent is rejected. Otherwise, the AuditEvent is accepted.
    • Constructor Summary

      Constructors 
      Constructor Description
      FilterSet()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean accept​(AuditEvent event)
      Determines whether or not a filtered AuditEvent is accepted.
      void addFilter​(Filter filter)
      Adds a Filter to the set.
      void clear()
      Clears the FilterSet.
      java.util.Set<Filter> getFilters()
      Returns the Filters of the filter set.
      void removeFilter​(Filter filter)
      Removes filter.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • FilterSet

        public FilterSet()
    • Method Detail

      • addFilter

        public void addFilter​(Filter filter)
        Adds a Filter to the set.
        Parameters:
        filter - the Filter to add.
      • removeFilter

        public void removeFilter​(Filter filter)
        Removes filter.
        Parameters:
        filter - filter to remove.
      • getFilters

        public java.util.Set<Filter> getFilters()
        Returns the Filters of the filter set.
        Returns:
        the Filters of the filter set.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • accept

        public boolean accept​(AuditEvent event)
        Description copied from interface: Filter
        Determines whether or not a filtered AuditEvent is accepted.
        Specified by:
        accept in interface Filter
        Parameters:
        event - the AuditEvent to filter.
        Returns:
        true if the event is accepted.
      • clear

        public void clear()
        Clears the FilterSet.