Package jakarta.mail.search
Class AndTerm
java.lang.Object
jakarta.mail.search.SearchTerm
jakarta.mail.search.AndTerm
- All Implemented Interfaces:
Serializable
This class implements the logical AND operator on individual
SearchTerms.
- See Also:
-
Constructor Summary
ConstructorDescriptionAndTerm
(SearchTerm[] t) Constructor that takes an array of SearchTerms.AndTerm
(SearchTerm t1, SearchTerm t2) Constructor that takes two terms. -
Method Summary
-
Constructor Details
-
AndTerm
Constructor that takes two terms.- Parameters:
t1
- first termt2
- second term
-
AndTerm
Constructor that takes an array of SearchTerms.- Parameters:
t
- array of terms
-
-
Method Details
-
getTerms
Return the search terms.- Returns:
- the search terms
-
match
The AND operation.The terms specified in the constructor are applied to the given object and the AND operator is applied to their results.
- Specified by:
match
in classSearchTerm
- Parameters:
msg
- The specified SearchTerms are applied to this Message and the AND operator is applied to their results.- Returns:
- true if the AND succeds, otherwise false
-
equals
Equality comparison. -
hashCode
public int hashCode()Compute a hashCode for this object.
-