To start with J2ME programming, first thing is to get our computer setup for development work. The steps listed below will help in building J2ME applications.

J2ME Development Tools.

Many development environment are used to develop and debug J2ME applications. J2ME Wireless Toolkit from Sun provides seamless environment for developing MIDLet Suites. It can be used as standalone or integrated with third party IDEs that provide support for J2ME. Several cellphone manufacturers provide their own development environments that can be used to develop and test MIDLets on their devices.

J2ME Specifications.

Wireless Toolkit 1.0 implementation is based on CLDC 1.0 and MIDP 1.0. Wireless Toolkit 2.0 implementation is based on CLDC 1.0/1.1 and MIDP 2.0. Later version supports backward compatibility and has many extra features. It will be good idea to install later version as it also supports optional JSR packages used for developing specific J2ME applications.

J2ME Emulators.

Wireless Toolkit comes with few default emulators. Many cell phone manufacturers produce their own device emulators that can be integrated with J2ME development environments.

Developing MIDLet Suites.

Wireless Toolkit is based around projects, that contains all the source files and resources for MIDLets.

  • Open Ktoolbar utility of wireless Toolkit.
  • Create new porject.
  • Supply project name, which will be used to create new directory to contain all of the project files, and MIDLet class name. By default the project directory is created under %Install_dir%/apps/project_name, where install_dir is directory where Wireless toolkit is installed.
  • Directory structure

    The toolkit uses this directory to store the manifest file for the JAR into which the MIDlet is packaged, the JAD file used to describe the MIDlet suite, and the MIDlet suite's JAR file itself.


    Contains the compiled class files for the MIDlet suite after they have been preverifed.


    source code for your MIDlets.

    Store resource files, such as images,that MIDlets in the MIDlet suite will need to access at runtime.


    It uses this directory to store compiled class files before they are preverified and copied into the classes directory.


    This directory can be used to hold JAR and ZIP files containing classes that are not part of the project you want to be incorporated when compiling,running, and packaging the MIDlet suite.


    This directory is used to hold copies of the JAR and ZIP files read from the project lib directory, in which the class files have been converted to their corresponding preverified forms.

  • Build and Run MIDLet.

Books on J2ME Programming


 Related Tips