|Oracle® Java Micro Edition Software Development Kit Developer's Guide
Release 3.2 for Eclipse on Windows
The Oracle® Java Micro Edition (Java ME) Software Development Kit (SDK) is a natural starting point for learning and using Java ME technology. The focus of the SDK is to provide emulation and deployment assistance during the development process. This chapter introduces the SDK and provides a quick introduction to using the SDK.
Using this simple yet powerful tool you can create, edit, compile, package, and sign an application. After testing your application in the Oracle Java ME SDK emulation environment, you can move to deploying and debugging on a real device.
This SDK provides supporting tools and sample implementations for the latest in Java ME technology. The SDK provides support for recent versions of the Connected Limited Device Configuration (CLDC) and Information Module Profile - Next Generation (IMP-NG).
As of version 3.2, the Java ME SDK is a plugin to the Eclipse IDE. Please see the Release Notes at:
The Oracle Java ME SDK plugin uses Eclipse technology, as described in the Eclipse online help. These tips offer some hints for getting started as quickly as possible.
Access the documentation. The online help is the primary documentation for the SDK. Many windows and dialogs feature a help button that opens context-sensitive help in the help viewer. You can also type F1.
Select Help > Help Contents to open the Eclipse Online Help viewer. Remember to use the search capability to help you find topics.
Run sample projects. Running sample projects is a good way to become familiar with the SDK.
See Section 3.2, "Running a Project" for a general overview of how to run a project.
The Oracle Java ME SDK has two components.
The Oracle Java ME SDK platform software installation includes the supported runtimes, emulation software, device configurations, supporting libraries, documentation (including Javadocs), the command line interface, and other utility executables. The default location of the SDK, as specified by its installer, is:
The Oracle Java ME SDK plugins for Eclipse add Oracle Java ME SDK technology to an Eclipse IDE installation running Mobile Tools for Java (MTJ). The outstanding feature of Oracle Java ME SDK is device emulation for the Connected Device Limited Configuration (CLDC). If the plugin is properly installed you will see the Device Selector tab on the bottom left, or, if it is not visible you can select Window > Show View > Device Selector.
The SDK provides two unique instances for most devices. For example, JavaMEPhone1 and JavaMEPhone2 are the same except for the device number and the phone number, so you can perform tests that require two devices (messaging, for example) without customization.
If the plugin is installed, and you cannot see the device selector you can add the Java ME SDK devices manually.
Select Window > Open Perspective > Other > Java ME and click OK.
Go to Window > Preferences > Java ME > Device Management and click on Manual Install.
In the Specify Search Directory field, insert the path to the Java ME SDK platform installation directory, and press Enter. The devices appear on the Devices table. Click on Finish and then click on OK. The device selector opens.
See the Package Explorer window and the Navigator window for a visual overview of the logical and physical layout of a project. When viewing items in the tree, use the context menu (right-click) to see the available actions.
A project has a default device that is used when it is run from the toolbar by clicking the green arrow or going to the Run menu and choosing Run.
To see a project's default device, expand the project node and double-click the Application Descriptor subnode. The project's Overview tab opens in the central editing area. The Runtime table on the bottom right of the Application Descriptor panel lists devices (execution environments) for the current project. The checked device will be used when the project is run. You can easily add, modify, or remove a device.
To run an application on different devices without changing the default device, right-click a device in the Device Selector pane, then select Run Project and choose an open project.
The emulator is an independent process, and when it has started it is a separate process from the build process running in Eclipse. Stopping the build process or closing a project does not always affect the application running in the emulator. You must be sure to terminate the application (the emulator can remain open). See Section 3.2, "Running a Project."
The Java ME SDK Update Center supports automatic updating of the entire Java ME SDK plugin, and individual modules within the Java ME SDK. To access the update center, select Help > Java ME SDK Update Center. The update manager works separately from the Eclipse Check for Updates function so that the Java ME SDK plugin components, including the Update Center, can be updated independently.
Oracle Java ME SDK is delivered as two plugins in a category named Java ME SDK Tools. The plugins are:
Java ME SDK Tools
Java ME SDK Demos
To detect updates, select Help > Java ME SDK Update Center and choose the Available tab. Any available updates are listed. Choose an update and click Install to update the plugin. The plugins then appear as activated on the Installed tab.
Demos are delivered separately for two reasons:
Some demos use network access for test purposes, however, the sample code does not include protection against malicious intrusion. Before using the demos, see the "Installation and Runtime Security Guidelines" in the Oracle Java Micro Edition Software Development Kit Release Notes.
Sample code has a different copyright that allows you to redistribute provided the Oracle copyright is kept.
For more on sample applications, see Chapter 3, "Using Sample Projects"