net.rim.blackberry.api.mail.event
Class MessageEvent
java.lang.Object
net.rim.blackberry.api.mail.event.MailEvent
net.rim.blackberry.api.mail.event.MessageEvent
public class MessageEvent
- extends MailEvent
Indicates that a message has changed.
The system produces a message event when a message's header attributes (envelope) is
updated, or when a message is opened, closed, created, forwarded or replied to in the
device's Message application.
Note: It is not possible to intercept a message during
transmission. Changes to the Message
object indicated by this message
event do not change data that has already been sent from the handheld.
Changes are reflected in the message in the messages list, however, and the
updated message can be retransmitted.
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 3.6.0
Field Summary |
|
static int |
CLOSED
Message was closed in the main message list UI. |
|
static int |
FORWARD
Message is forwarded. |
|
static int |
NEW
The compose screen is opened to create a new message. |
|
static int |
OPENED
Message was opened in the main message list UI. |
|
static int |
REPLY
Reply to a message. |
|
static int |
UPDATED
Message header attributes (envelope) changed, but not the message body. |
UPDATED
public static final int UPDATED
- Message header attributes (envelope) changed, but not the message body.
- See Also:
- Constant Field Values
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 3.6.0
OPENED
public static final int OPENED
- Message was opened in the main message list UI.
- See Also:
- Constant Field Values
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 4.0.0
CLOSED
public static final int CLOSED
- Message was closed in the main message list UI.
- See Also:
- Constant Field Values
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 4.0.0
NEW
public static final int NEW
- The compose screen is opened to create a new message.
- See Also:
- Constant Field Values
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 4.1.0
FORWARD
public static final int FORWARD
- Message is forwarded.
- See Also:
- Constant Field Values
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 4.1.0
REPLY
public static final int REPLY
- Reply to a message.
- See Also:
- Constant Field Values
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 4.1.0
MessageEvent
public MessageEvent(int type,
Message msg)
- Creates a new MessageEvent instance.
- Parameters:
type
- Type of this event:
MessageEvent.UPDATED
,
MessageEvent.OPENED
,
MessageEvent.CLOSED
,
MessageEvent.NEW
,
MessageEvent.FORWARD
, or
MessageEvent.REPLY
.msg
- Message associated with the event.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 3.6.0
dispatch
public void dispatch(Object listener)
- Dispatches this event to provided listener.
- Specified by:
dispatch
in class MailEvent
- Parameters:
listener
- Listener to handle this event.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 3.6.0
getMessage
public Message getMessage()
- Returns the changed message.
- Returns:
- Message that was changed by this event.
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 3.6.0
getMessageChangeType
public int getMessageChangeType()
- Retrieves this event's type.
- Returns:
- Type of message event:
MessageEvent.UPDATED
,
MessageEvent.OPENED
,
MessageEvent.CLOSED
,
MessageEvent.NEW
,
MessageEvent.FORWARD
, or
MessageEvent.REPLY
. - Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 3.6.0
toString
public String toString()
- Converts this event into a string.
- Overrides:
toString
in class MailEvent
- Returns:
- String form for this event.
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 4.0.0
Copyright 1999-2010 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Copyright 1993-2003 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A. All Rights Reserved.
Copyright 2002-2003 Nokia Corporation All Rights Reserved.
Java is a trademark of Sun Microsystems, Inc.