Top Description Fields Constructors Methods
javax.mail.search

public final Class SubjectTerm

extends StringTerm
Class Inheritance
Imports
javax.mail.Message

This class implements comparisons for the message Subject header. The comparison is case-insensitive. The pattern is a simple string that must appear as a substring in the Subject.
Authors
Bill Shannon, John Mani

Field Summary

Modifier and TypeField and Description
private static final long
Inherited from javax.mail.search.StringTerm:
ignoreCasepattern

Constructor Summary

AccessConstructor and Description
public
SubjectTerm(String
the pattern to search for
pattern
)

Constructor.

Method Summary

Modifier and TypeMethod and Description
public boolean
equals(Object
the reference object with which to compare.
obj
)

Overrides javax.mail.search.StringTerm.equals.

Equality comparison.
public boolean

Returns:

true if the pattern match succeeds, otherwise false
match
(Message
the pattern match is applied to this Message's subject header
msg
)

Implements abstract javax.mail.search.SearchTerm.match.

The match method.
Inherited from javax.mail.search.StringTerm:
getIgnoreCasegetPatternhashCodematch

Field Detail

serialVersionUIDback to summary
private static final long serialVersionUID

Hides javax.mail.search.StringTerm.serialVersionUID.

Constructor Detail

SubjectTermback to summary
public SubjectTerm(String pattern)

Constructor.

Parameters
pattern:String

the pattern to search for

Method Detail

equalsback to summary
public boolean equals(Object obj)

Overrides javax.mail.search.StringTerm.equals.

Equality comparison.

Parameters
obj:Object

Doc from java.lang.Object.equals.

the reference object with which to compare.

Returns:boolean

Doc from java.lang.Object.equals.

true if this object is the same as the obj argument; false otherwise.

Annotations
@Override
matchback to summary
public boolean match(Message msg)

Implements abstract javax.mail.search.SearchTerm.match.

The match method.

Parameters
msg:Message

the pattern match is applied to this Message's subject header

Returns:boolean

true if the pattern match succeeds, otherwise false

Annotations
@Override