Interface Filter<T>

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      boolean accept​(T candidate)
      Method that is invoked to determine if a candidate instance should be accepted or not.
      void initialize​(org.apache.maven.plugin.logging.Log log)
      Initializes this Filter, and assigns the supplied Log for use by this Filter.
      boolean isInitialized()  
    • Method Detail

      • initialize

        void initialize​(org.apache.maven.plugin.logging.Log log)
        Initializes this Filter, and assigns the supplied Log for use by this Filter.
        Parameters:
        log - The non-null Log which should be used by this Filter to emit log messages.
      • isInitialized

        boolean isInitialized()
        Returns:
        true if this Filter has been properly initialized (by a call to the initialize method).
      • accept

        boolean accept​(T candidate)
                throws java.lang.IllegalStateException

        Method that is invoked to determine if a candidate instance should be accepted or not. Implementing classes should be prepared to handle null candidate objects.

        Parameters:
        candidate - The candidate that should be tested for acceptance by this Filter.
        Returns:
        true if the candidate is accepted by this Filter and false otherwise.
        Throws:
        java.lang.IllegalStateException - if this Filter is not initialized by a call to the initialize method before calling this matchAtLeastOnce method.