Java ME

Java Mobility

This application provides a java programmer with java mobility functionality.

========== Installation Guide (Full Installation) Guide ==========

Download the jdk 1.8

Download the java me platform sdk 8.0 kit

Download the midp 2.0 runtime

Install eclipse

Eclipse > Help > Install New Software > URL: http://download.eclipse.org/releases/indigo

========== Java ME Library: (Java Libraries) ==========

cldc_1.8.jar

configuration_1.0.jar

device-io_1.0.jar

gcf_1.8.jar

httpclient_1.0.jar"

json_1.0.jar

embedded-support-api.jar

security_api.jar

antenna-bin-0.9.11.jar

midpapi20-2.0.4.jar

========== Java ME Syntax ==============

JDK=Java Development Kit 1.6

JWT=Java Wireless Toolkit 2.5

JAD=Java Application Descriptor

JAM=Java Application Manager (Games)

MIDP=Mobile Information Device Profile 2.0

MIDlet=Mobile Information Device Application

CLDC=Connected Limited Device Configuration 1.1

========== Java ME JAD File ==============

# Required Attributes

MIDlet-Name: NameMIDlets

MIDlet-Version: 1.0

MIDlet-Vendor: Vendor

MIDlet-1: Name, Icon Filename, com.company.NameMIDlets

MIDlet-2: Name, Icon Filename, Class

MicroEdition-Profile: MIDP-2.0

MicroEdition-Configuration: CLDC-1.1

# Option Attributes

MIDlet-Icon: Icon

MIDlet-Description: Description

MIDlet-Jar-URL: NameMIDlets.jar

MIDlet-Jar-Size: 14723

MIDlet-Data-Size: 14723

Obtain the precise size for the jar file from the directory list from a command prompt

MIDlet-Jar-Size: 316

========== Initial commands ==============

The commands in this file are set up for you hello.java file.

To reuse it for other files, change the Hello to whatever you have named your file/class.

Compile command for the *.java file:

javac -target 1.6 -bootclasspath %MIDP_HOME%\classes Hello.java

After you compile you, the *.class file is generated.

Then issue the preverify command:

preverify -cldc -classpath %MIDP_HOME%\classes;. -d . Hello

Issue the run command:

midp -classpath . Hello

Command to create the jar file from the manifest

jar -cvfm HelloMIDlet.jar HelloMIDlet.jad *.class

Issue this to show the contents of the jar file

jar -tvf HelloMIDlet.jar

To run the JAD file

midp -classpath . -Xdescriptor HelloMIDlet.jad

========== Java ME commands ==============

javac -target 1.6 -bootclasspath %MIDP_HOME%\classes Hello.java

preverify - cldc - classpath %MIDP_HOME%\classes;. -d Hello

midp -version

midp -classpath %MIDP_HOME%\classes -d . Hello

midp -classpath . -Xdescriptor HelloMIDlet.jad

jar -cvfm HelloMIDlet.jar manifest.txt *.class

jar -tvf HelloMIDlet.jar

========== Java ME Directory Description ==============

/appdb=Graphics File of the *.png type

/bin=Command Line Tools, preverify.exe and the midp.exe emulator

/build=Makefile for building the MIDP for Windows

/classes=MIDP classes, you'll compile using these as a base

/docs=documenation of MIDP, guides reference materials, and relase notes

/example=example jars and jad for demonstration purposes

/lib=Java ME jar files

/src=Source code

/tools=primarily the jad tool,which you use for midlet suites

=========== Shell Environment Variables ======

JAVA_HOME="C:\Developer\Java\jdk1.8.0_181"

JRE_HOME="C:\Developer\Java\jdk1.8.0_181\jre"

JAVA_ME="C:\Developer\Java\Java_ME_platform_SDK_8.0"

MIDP_HOME="C:\Developer\Java\Java_ME_platform_SDK_8.0\runtimes\meep\bin"

ECLIPSE="c:\Developer\eclipse"

=========== build.xml ======

New build tasks: jadtool, runMidlet, testMidlet

========== Java ME Commands ==============

cref.exe

device-editor.exe

device-manager.exe

device-selector.exe

emulator.exe

jadtool.exe

mekeytool.exe

update-center.exe

wma-tool.exe

wscompile.exe

runMidlet.exe

========== Java ME Notes ==============

The build.xml file has been updated from Netbeans 8.2 script, updated build.properties file

Note: You can update the build.properties file for javac.source and target from 1.6 -> 1.8

The application.xml file has been updated to build the MIDIets distribution file from the jad files

Installing Plugins on Eclipse Juno 4.0

Java ME LIbrary:

    • Download eclipse plugin

Java ME Instructions

    • On Eclipse Juno 4.2, installing the Oracle Java ME SDK plugins requires the Eclipse Mobile Tools for Java (MTJ) toolkit. The MTJ is not bundled with Juno and must be installed manually, before installing the Eclipse plugins.
    • To install the Eclipse Mobile Tools for Java toolkit:
        1. Go to Help > Install New Software.
        2. In the “Work with” field, enter this
          1. URL: http://download.eclipse.org/releases/indigo
        3. Click Add.
        4. When the plugins are discovered, open the Mobile and Device Development Tools hierarchy and check Mobile Tools for Java Examples and Mobile Tools for Java SDK.
        5. Uncheck the "Contact all update sites...." checkbox and click Next.
        6. On the installation screen select all plugins and click Finish. Then click OK.
  • Eclipse Java ME Plugin Instructions