Creating a new J2ME MIDlet Project
This document illustrates how to create a new J2ME MIDlet Project using EclipseME.
In order to create a new EclipseME project, use the New Project Wizard and select J2ME Midlet Suite from within the J2ME item.
The first wizard pane is standard for almost all Eclipse projects. Here, you provide the name of the project, and the location for the project contents.
In the second pane, you choose which of the installed platform definitions you will use for compiling the project and for running and debugging. If necessary, you can change this setting later using the Project Properties.
The final pane provides you with the opportunity to adjust source settings, related projects and libraries, etc. These are standard Eclipse settings. If your project requires an external library (e.g. kXML, etc.), add the JAR file(s) to the list on the "Libraries" tab. EclipseME will automatically manage these JAR files along with your compiled class files.
Once you have completed the above steps, you will have a project that looks like this in your workspace:
If you have an existing Java project that you want to convert into an EclipseME project, you can do this by selecting Convert to J2ME Midlet Suite from the project pop-up menu.
When you do this, the EclipseME plug-in will automatically prompt you for the appropriate profile selection, and will then make the required changes to your project.
If a J2SE project is converted to an EclipseME project, the J2SE libraries need to be removed from the build path. If EclipseME can identify these libraries, it will remove them automatically. If EclipseME does not remove the J2SE libraries, you will need to do this yourself.
EclipseME also handles adding the appropriate J2ME libraries to your project automatically. The specific libraries added are based on the current profile selection. If you were using Eclipse to do J2ME programming prior to converting your project to use EclipseME, your project may still have the J2ME libraries in the build path. If so, you need to remove them. Failure to do this may cause problems, since EclipseME may misinterpret these libraries as additional classes that need to be bundled into your JAR file.
After creating a new MIDlet Suite Project you may find that you need to alter the suite's properties. MIDlet Suite properties are controlled by the editing the Java Application Descriptor.