Class Finder.Filter

    • Constructor Summary

      Constructors 
      Constructor Description
      Filter()  
    • Method Summary

      All Methods Static Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      (package private) static Finder.Filter and​(Finder.Filter[] filters)
      Returns a filter which passes a file iff so do all filters in filters.
      (package private) Finder.Filter not()
      Returns a filter which passes a file iff filter does not.
      (package private) static Finder.Filter or​(Finder.Filter[] filters)
      Returns a filter which passes a file iff at least one filter in filters does so.
      (package private) abstract boolean pass​(java.io.File file)
      Returns for the given file whether this file passes this filter.
      • Methods inherited from class java.lang.Object

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

      • Filter

        Filter()
    • Method Detail

      • pass

        abstract boolean pass​(java.io.File file)
        Returns for the given file whether this file passes this filter.
      • not

        Finder.Filter not()
        Returns a filter which passes a file iff filter does not. This corresponds the tests \! expr1 in the original find command.
      • and

        static Finder.Filter and​(Finder.Filter[] filters)
        Returns a filter which passes a file iff so do all filters in filters. This corresponds the tests expr1 -a .... exprn and expr1 -and .... exprn in the original find command.
        Parameters:
        filters - a sequence of filters which may be empty. If empty, this filter passes all files like Finder.TRUE.
        Returns:
        a lazy and-filter of type Finder.AndFilter. For more details see there.
      • or

        static Finder.Filter or​(Finder.Filter[] filters)
        Returns a filter which passes a file iff at least one filter in filters does so. This corresponds the tests expr1 -o .... exprn and expr1 -or .... exprn in the original find command.
        Parameters:
        filters - a sequence of filters which may be empty. If empty, this filter passes no file like Finder.FALSE.
        Returns:
        a lazy and-filter of type Finder.AndFilter. For more details see there.