com.groupdocs.search

Class DocumentFilter



  • public abstract class DocumentFilter
    extends Object

    DocumentFilter class is designed for creating documents filters.

    • Constructor Detail

      • DocumentFilter

        public DocumentFilter()
    • Method Detail

      • toString

        public abstract String toString()

        Returns string representation of document filter.

        Overrides:
        toString in class Object
        Returns:
        String representation of document filter.
      • createCreationTimeLowerBound

        public static DocumentFilter createCreationTimeLowerBound(com.aspose.ms.System.DateTime lowerBound)

        Create filter for skipping documents with creation date earlier than specified.

        Parameters:
        lowerBound - Lower bound of document creation time.
        Returns:
        Document filter for document creation time.
      • createCreationTimeUpperBound

        public static DocumentFilter createCreationTimeUpperBound(com.aspose.ms.System.DateTime upperBound)

        Create filter for skipping documents with creation date later than specified.

        Parameters:
        upperBound - Upper bound of document creation time.
        Returns:
        Document filter for document creation time.
      • createCreationTimeRange

        public static DocumentFilter createCreationTimeRange(com.aspose.ms.System.DateTime lowerBound,
                                             com.aspose.ms.System.DateTime upperBound)

        Create filter for skipping documents with creation date in specified range.

        Parameters:
        lowerBound - Lower bound of document creation time.
        upperBound - Upper bound of document creation time.
        Returns:
        Document filter for document creation time.
      • createModificationTimeLowerBound

        public static DocumentFilter createModificationTimeLowerBound(com.aspose.ms.System.DateTime lowerBound)

        Create filter for skipping documents with modification date earlier than specified.

        Parameters:
        lowerBound - Lower bound of document modification time.
        Returns:
        Document filter for document modification time.
      • createModificationTimeUpperBound

        public static DocumentFilter createModificationTimeUpperBound(com.aspose.ms.System.DateTime upperBound)

        Create filter for skipping documents with modification date later than specified.

        Parameters:
        upperBound - Upper bound of document modification time.
        Returns:
        Document filter for document modification time.
      • createModificationTimeRange

        public static DocumentFilter createModificationTimeRange(com.aspose.ms.System.DateTime lowerBound,
                                                 com.aspose.ms.System.DateTime upperBound)

        Create filter for skipping documents with modification date in specified range.

        Parameters:
        lowerBound - Lower bound of document modification time.
        upperBound - Upper bound of document modification time.
        Returns:
        Document filter for document modification time.
      • createFileNameRegularExpression

        public static DocumentFilter createFileNameRegularExpression(String pattern)

        Create filter for skipping documents using regular expression.

        Parameters:
        pattern - Regex pattern.
        Returns:
        Document filter for file name.
      • createFileNameRegularExpression

        public static DocumentFilter createFileNameRegularExpression(String pattern,
                                                     int options)

        Create filter for skipping documents using regular expression.

        Parameters:
        pattern - Regex pattern.
        options - Regex options.
        Returns:
        Document filter for file name.
      • createFileLengthLowerBound

        public static DocumentFilter createFileLengthLowerBound(long lowerBound)

        Create filter for skipping documents with length less than specified.

        Parameters:
        lowerBound - Lower bound of document length.
        Returns:
        Document filter for document length.
      • createFileLengthUpperBound

        public static DocumentFilter createFileLengthUpperBound(long upperBound)

        Create filter for skipping documents with length more than specified.

        Parameters:
        upperBound - Upper bound of document length.
        Returns:
        Document filter for document length.
      • createFileLengthRange

        public static DocumentFilter createFileLengthRange(long lowerBound,
                                           long upperBound)

        Create filter for skipping documents in specified length range.

        Parameters:
        lowerBound - Lower bound of document length.
        upperBound - Upper bound of document length.
        Returns:
        Document filter for document length.
      • createFileExtension

        public static DocumentFilter createFileExtension(String... extensions)

        Create filter for skipping documents with specified extensions.

        Parameters:
        extensions - Extensions for filtering documents.
        Returns:
        Document filter for document extensions.
      • createInverted

        public static DocumentFilter createInverted(DocumentFilter innerFilter)

        Invert document filter.

        Parameters:
        innerFilter - Document filter.
        Returns:
        Inverted document filter.
      • createConjunction

        public static DocumentFilter createConjunction(DocumentFilter... filters)

        Create logical conjunction (logical and) of specified filters.

        Parameters:
        filters - Document filters.
        Returns:
        Document filter that represents result of conjunction of specified filters.
      • createDisjunction

        public static DocumentFilter createDisjunction(DocumentFilter... filters)

        Create logical disjunction (logical or) of specified filters.

        Parameters:
        filters - Document filters.
        Returns:
        Document filter that represents result of disjunction of specified filters.