BlackBerry application integration
7
Adding custom menu items
A BlackBerry® Java® Application can add custom menu items to the menu on the BlackBerry device for the email, organizer, and
phone applications. When a BlackBerry device user selects the custom menu item, theBlackBerry Java Application starts with a
reference to the object that the BlackBerry device user selects. For example, a BlackBerry Java Application can add a menu item
called Show Location of Sender to the email application. When the BlackBerry device user selects the menu item, the BlackBerry
Java Application starts with a reference to the email object that is currently highlighted or that the user opens. The BlackBerry
Java Application uses the email address of the sender to determine the location of the sender by retrieving the email address
from the contact list, or by retrieving data from a remote server, and then comes to the foreground and displays a map.
Integrating with BlackBerry Device Software applications
A BlackBerry® device application can invoke a BlackBerry Device Software application such as the email, organizer, phone,
browser, and camera applications to perform an action or display information. The following examples demonstrate how a
BlackBerry device application can invoke a BlackBerry Device Software application:
•
The BlackBerry device application invokes the calendar to display a specific date or calendar entry.
•
The BlackBerry device application invokes the address book to display a specific contact.
•
The BlackBerry device application invokes the browser to open a specific web address.
•
The BlackBerry device application invokes the phone to dial a specific number.
Accessing email and organizer data
A BlackBerry® Java® Application can use the BlackBerry APIs to access the details of email messages, contacts, calendar events,
tasks, and phone logs that the BlackBerry device stores. A BlackBerry Java Application can read the information, update the
information, and create new entries.
Using BlackBerry Messenger with a BlackBerry Application
You can integrate a BlackBerry® Java® Application with the BlackBerry® Messenger application. This could be useful if you are
creating a turn-based game application for the BlackBerry device.
To create a BlackBerry Java Application that integrates with the BlackBerry Messenger application, you can use the classes in
the
net.rim.blackberry.api.blackberrymessenger
package. For more information about using the
BlackBerryMessenger
class, see the BlackBerry API Reference .
Fundamentals Guide
BlackBerry application integration
33