All Packages Class Hierarchy This Package Previous Next Index
Class com.ibm.network.mail.base.Flags
java.lang.Object
|
+----com.ibm.network.mail.base.Flags
- public class Flags
- extends Object
- implements Serializable
This class encapsulates various flags that can be associated with a message.
- Author:
- Abdul Majeed Ghadialy
- See Also:
- MimeMessage
-
DELETED
-
-
RECENT
-
-
SEEN
-
-
Flags(boolean, boolean)
- Constructor for
Flags
.
-
Flags(boolean, boolean, boolean)
- Constructor for
Flags
.
-
isDeleted()
- Returns 'true' if the message is deleted.
-
isRecent()
- Returns 'true' if the message is recent i.e, the message has never been shown to the
user.
-
isSeen()
- Returns 'true' if the message has been seen by the user i.e, the message has been shown
to him atleast once.
-
isSet(String)
- Returns 'true' if the specified flag is set.
-
setDeleted(boolean)
- Indicates whether the message is to be marked as deleted.
-
setRecent(boolean)
- Indicates whether the message is to be marked as recent.
-
setSeen(boolean)
- Indicates whether the message is to be marked as seen.
RECENT
public static final String RECENT
SEEN
public static final String SEEN
DELETED
public static final String DELETED
Flags
public Flags(boolean recent,
boolean seen)
- Constructor for
Flags
.
Creates a Flags
object with specified recent
and
seen
values.
- Parameters:
- recent - boolean
- seen - boolean
Flags
public Flags(boolean recent,
boolean seen,
boolean deleted)
- Constructor for
Flags
.
Creates a Flags
object with specified recent
,
seen
and deleted
values.
- Parameters:
- recent - boolean
- seen - boolean
- deleted - boolean
isDeleted
public boolean isDeleted()
- Returns 'true' if the message is deleted.
- Returns:
-
true
if the message is deleted;
false
otherwise.
isRecent
public boolean isRecent()
- Returns 'true' if the message is recent i.e, the message has never been shown to the
user.
- Returns:
-
true
if the message is recent;
false
otherwise.
isSeen
public boolean isSeen()
- Returns 'true' if the message has been seen by the user i.e, the message has been shown
to him atleast once.
- Returns:
-
true
if the message is seen;
false
otherwise.
isSet
public boolean isSet(String flagName)
- Returns 'true' if the specified flag is set.
- Parameters:
- flagName - java.lang.String can be
Flags.SEEN, Flags.RECENT and Flags.DELETED
- Returns:
-
true
if the specified flag is set;
false
otherwise.
setDeleted
public void setDeleted(boolean deleted)
- Indicates whether the message is to be marked as deleted.
- Parameters:
- deleted - true if message is to be marked as deleted, false otherwise.
setRecent
public synchronized void setRecent(boolean recent)
- Indicates whether the message is to be marked as recent.
- Parameters:
- recent - true if message is to be marked as recent, false otherwise.
setSeen
public synchronized void setSeen(boolean seen)
- Indicates whether the message is to be marked as seen.
- Parameters:
- seen - true if message is to be marked as seen, false otherwise.
All Packages Class Hierarchy This Package Previous Next Index