Sun Microsystems J2ME manual Run=storagename storagenumber

Models: J2ME

1 134
Download 134 pages 62.02 Kb
Page 118
Image 118

For example, a JAD file might have the following contents:

MIDlet-Name: MyMIDlet

MIDlet-Vendor: My Organization

MIDlet-Version: 1.0

MIDlet-Jar-URL: MyApp.jar

MIDlet-Jar-Size: 24601

B.2.3 Run

You can run the emulator from the command line. The J2ME Wireless Toolkit’s bin directory contains the command emulator. The syntax for the emulator command is as follows:

emulator [options]

The general options are:

-help: Display a list of valid options.

-version: Display version information about the emulator.

-Xquery: Print emulator skin information on the standard output stream and exit immediately. The information includes the skin name, screen size, and other capabilities.

Options that pertain to running MIDlet suites are:

-Xdevice:<skin_name>: Run an application on the emulator using the given skin name. For a list of skin names, see Chapter 4, “Using the Emulator.”

-Xdescriptor:<jad_file>: Run an application locally using the given JAD file.

-classpath<classpath>: Specify the classpath for libraries required to run the application. Use this option when running an application locally.

-D<runtime_property>: Set the HTTP and HTTPS proxy servers. Valid properties include:

com.sun.midp.io.http.proxy=<proxy host>:<proxy port>

-Xjam:<command>=<application>: Run an application remotely using the Application Management System (AMS) to run using OTA provisioning. If no application is specified with the argument, the graphical AMS is run.

install=<jad_file_url> force list storageNames

Install the application with the specified JAD file onto a device.

run=[<storage_name> <storage_number>]

Run a previously installed application. The application is specified by its valid storage name or storage number.

106 J2ME Wireless Toolkit User’s Guide • October 2004

Page 118
Image 118
Sun Microsystems J2ME manual Run=storagename storagenumber