Oracle® Java Micro Edition Software Development Kit Developer's Guide Release 8 for Windows E50624-01 |
|
Previous |
Next |
The Oracle Java ME SDK 8 Embedded Emulator can be started from the Windows command line. After the emulator starts, it runs and behaves the same as it does when started from NetBeans IDE 8.0.
Starting the emulator from the Windows command line enables you to use a number of emulator options. For more information, see Useful Emulator Command Options.
You can find the Oracle Java ME SDK 8 command-line emulator under bin
in the Oracle Java ME SDK 8 installation directory.
To start the emulator from the Windows command line:
Open the Windows command prompt. There are several ways to do this:
Press Win+R on the keyboard, or open the Start menu and select Run to open the Run window. Now, type cmd
and click OK.
Open the Start menu, search for cmd.exe
and run it.
Double-click C:\Windows\System32\cmd.exe
.
Change to the bin
directory in the Oracle Java ME SDK 8 installation directory. For the default location, use the following command:
> cd C:\Java_ME_platform_SDK_8.0\bin
Run the emulator.exe
command. Use the -Xdevice
option to specify the device you would like to run, and the -Xdescriptor
option to specify the JAD file you would like to run on the device. For example, to run the sample_imlet.jad
file on EmbeddedDevice1, use the following command:
C:\Java_ME_platform_SDK_8.0\bin> emulator.exe -Xdevice:EmbeddedDevice1 -Xdescriptor:C:\Java_ME_platform_SDK_8.0\apps\sample\sample_imlet.jad
Note: You can run the |
The emulator
command can be used with the following command-line options:
Displays usage information with a complete list of command-line options.
Displays a list of installed IMlets.
Displays a list of supported devices.
Installs a JAD file over the air and executes the IMlet. You must specify a URL of the JAD file, for example:
> emulator -Xjam:install=http://www.example.com/TestJAD.jad
Runs an IMlet. You must specify either the storage name or storage number, which can be displayed using the -Xjam:list
command.
Removes an IMlet. To remove a specific IMlet, you must specify either the storage name or storage number, which can be displayed using the -Xjam:list
command. To remove all IMlets, specify all
as the parameter.
Installs a JAD file, executes the IMlet locally, and removes it after completion. You must specify the path and name of the JAD file, for example:
> emulator -Xdescriptor:C:\imlets\sample.jad
Runs an IMlet in autotest mode. You must specify the URL of the JAD file, for example:
> emulator -Xautotest:http://127.0.0.1:8080/getNextApp.jad