Creating Java extensions for BlackBerry 7 and earlier

Although a BlackBerry WebWorks application can offer a wide range of functionality, that functionality is limited to the resources that are contained within the application. A JavaScript extension allows you to extend the functionality of your BlackBerry WebWorks application to include the functionality provided by BlackBerry APIs and Java APIs that are available to a BlackBerry Java Application.

A JavaScript extension is code that is built into a WebWorks application and can be accessed through JavaScript. You can pass parameters into the extended function and handle return values as you would in a BlackBerry Java Application.

A JavaScript extension allows you to access the functionality that the BlackBerry APIs provide such as accessing the file system on a BlackBerry device, triggering notifications on the device (such as making the device vibrate in response to an event).

Creating a BlackBerry WebWorks extension involves two parts:

  1. Creating the Java part of the extension.
  2. Using the extension in your app.

Last modified: 2013-08-14