Question

I've been trying to find a way to play with Xlet development (as a part of Personal Basis Profile in javax.microedition.xlet package).

Currently as a starting point I have Eclipse Indigo (I do Android development in it).

My questions are:

  • What steps should I do to setup a development environment for Xlets?
  • Is there any emulator to run an Xlet on?
Was it helpful?

Solution

I'm not sure if my experience helps but at least it provides a reference. My environment is a linux x86 PC (linux 2.6) + eclipse 3.2 + j2se 1.4.2_09 I downloaded javatv 1.0 / 1.1 source codes of reference implementation from sun.

You can create a project in eclipse where imports all source codes. Please fix all possible errors (if any). Usually if there are some, just comment them.

Finally, please export the project as a jar file.

You can then create another project and configure the build path, click "import external jars" to import the generated javatv jar. Now you can create your own xlet by creating a java file which implements javax.tv.Xlet.xlet interface in the same project.

To execute the xlet, you need to implement main method and create an instance of SIEmulator (assume myemulator). And then you can call myemulator.putResidentXlet() and fill name / path of the xlet in. Finally please go to the output folder (which contains the compiled class file of the source codes, usually folder "bin"), type "java -Djava.class.path="path of the javatv jar" class_containing_main_method

Note that the xlet executed is NOT in a service context. If you wish to run in a service context, you either need to modify codes in com.sun.tv.XletManager.java to fill a service context object for the xlet or put the xlet's info in javatv's SI source, an xml file. Default is "JavaTVSampleFile01.xml". The usage please refer to javatv's documents.

That was from a forum post. LINK: https://forums.oracle.com/forums/thread.jspa?messageID=7310245

Your best chance for file downloads: http://docs.oracle.com/javame/config/cdc/cdc-opt-impl/ojmeec/1.0/reference/html/z4000c841293984.html

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top