Class NullFilter

  • All Implemented Interfaces:
    Filter<Object>

    public final class NullFilter
    extends Object
    implements Filter<Object>
    A null implementation of a Filter. The singleton instance can be typed cast properly when using generics.
    Since:
    2.3
    Version:
    2.3
    Author:
    Pascal Filion
    • Method Detail

      • instance

        public static <T> Filter<T> instance()
        Returns the singleton instance of this NullFilter.
        Returns:
        The singleton instance
      • accept

        public boolean accept​(Object value)
        Determines whether the specified object is "accepted" by the filter. The semantics of "accept" is determined by the contract between the client and the server.
        Specified by:
        accept in interface Filter<Object>
        Parameters:
        value - The value to filter
        Returns:
        true if the given value is "accepted" by this filter; false if it was "rejected"