public final class OrTerm extends SearchTerm
Constructor and Description |
---|
OrTerm(SearchTerm[] t)
Constructor that takes an array of SearchTerms.
|
OrTerm(SearchTerm t1,
SearchTerm t2)
Constructor that takes two operands.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj)
Equality comparison.
|
SearchTerm[] |
getTerms()
Return the search terms.
|
int |
hashCode()
Compute a hashCode for this object.
|
boolean |
match(Message msg)
The OR operation.
|
public OrTerm(SearchTerm t1, SearchTerm t2)
t1
- first termt2
- second termpublic OrTerm(SearchTerm[] t)
t
- array of search termspublic SearchTerm[] getTerms()
public boolean match(Message msg)
The terms specified in the constructor are applied to the given object and the OR operator is applied to their results.
match
in class SearchTerm
msg
- The specified SearchTerms are applied to this Message
and the OR operator is applied to their results.public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object