Skip Headers
Oracle® Java Micro Edition Software Development Kit Developer's Guide
Release 3.2 for Eclipse on Windows
E37550-02
  Go To Table Of Contents
Contents
Go To Index
Index

Previous
Previous
 
Next
Next
 

4 Viewing and Editing Project Properties

All projects have properties. Some properties, such as the project's name and location cannot be changed, but other properties can be freely edited as work on your project progresses. To view or edit a project's properties, right-click the project node and select Properties. In the resulting window, you can view and customize the project properties. See the following topics:

4.1 Project Properties

To view the project properties, right-click on a project, choose Properties, and select the Java ME category. The Java ME category enables you to select the emulator platform and configuration for the project, and it contains the following subcategories: library, obfuscation, packaging, preprocessor, preverification and signing.

4.2 Platform Selection

An emulator platform simulates the execution of an application on one or more target devices. To view this property page, right-click on a project and choose Properties and select the Java ME category.

Select a configuration from the table. You can edit the configuration and choose the SDK platform and the device that you want to use for this project.

For the emulator platform, be sure to select the 3.2 platform. You might have to use the dropdown menu to ensure the right version is selected.

By default, the devices in the device menu are also suitable for the platform type and emulator platform. The device you select is the default device for this project. It is used whenever you use the Run command. Your device selection influences the Device Configuration and Device Profile options, and the available optional packages.

Add the optional packages you want to include in this project. The selected APIs are automatically added to the project's classpath.

4.3 Editing Application Descriptor Properties

In Eclipse, the application descriptor is an element in the Package Explorer window. Double click on Application Descriptor in the Package Explorer under your project tree and edit the properties on the window that appears. There are different categories of properties on the tabs on the bottom: Overview, MIDlets, Optional, User Defined, Signing, etc.

4.4 Building a Project

When you build a project, the SDK compiles the source files and generates the packaged build output (a JAR file) for your project. You can build the main project and all of its required projects, or build any project individually.

In general you do not need to build the project or compile individual classes to run the project. By default, the SDK automatically compiles classes when you save them. You can use properties to modify the following build tasks:

4.4.1 Compiling

To view this property page, right-click on a project and choose Properties. Choose the Java Compiler category. In this category and its subcategories you can choose the Java compiler options and other compilation options.

4.4.2 Adding Libraries and Resources

To view this property page, right-click on a project and choose Properties. In the Java ME category, choose the Library subcategory. Here you can add libraries to your project.

4.4.3 Creating JAR and JAD Files (Packaging)

To view this property page, right-click on a project and choose Properties. In the Java ME category, choose the Packaging subcategory.

4.4.4 Obfuscating

To view this property page, right-click on a project and choose Properties. In the Java ME category, choose the Obfuscation subcategory.

4.4.5 Signing

To view this property page, right-click on a project and choose Properties. In the Java ME category, choose the Signing subcategory.

4.5 Running Settings

To view this property page, right-click on a project and choose Properties. In the Properties window, choose Run/Debug Settings. The options shown depend on the platform. See Section 4.5.1, "MIDP Project Run Options."

4.5.1 MIDP Project Run Options

To set emulator command line options for a MIDP project, type in the command line switches. See Section 11.3, "Emulator Command Line Options."

To view the running settings page, right-click on a project and choose Properties. Select the Run/Debug Settings category and click on New. Select Java Application and click OK. In the window that appears you can adjust the run options for your project.