[java]
[java] Hits - Class:95.74% Monitor:92.38% Exit:100.00% New:98.43%
[java] GCs: 2 full, 0 partial
[java] ** VM stopped: exit code = 0 **
[java] Exiting
[delete] Deleting:
run:
BUILD SUCCESSFUL
Total time: 10 seconds
C:\MyApplication>
As you can see, this application just prints “Hello world!” However, it gives you a framework to use for your applications.
N.B. After your Sun SPOT has printed “Hello world!” it probably will not exit immediately. Instead, you will have to push the control button to force it to exit. This is because by default, Sun SPOTs run a background thread which listens for
As a shortcut, the ant command “deploy” combines
ant deploy run
Deploying a pre-existing jar
To deploy an application that has already been built into a suitable jar (by using the “ant
ant
Incorporating utility classes into your application
You can include code from
ant deploy
You can specifiy multiple utility jars as a list separated by a classpath delimiter (“;” or “:”). Note that you may need to enclose the list in quotes. Also, the classes in the utility jars must all be preverified. One way to ensure this is to create the jar using
ant
Resource files in utility jars will be included in the generated jar, but its manifest is ignored.
If you have code that you want to include as part of all your applications you might consider building it into the system library – see the section Advanced topics in this document.
12