Science Fair Project Encyclopedia
MIDlet
A MIDlet is a Java program for embedded devices, more specifically the J2ME virtual machine. Generally, these are games and applications that run on a cell phone.
MIDlets will (should) run on any device that implements J2ME Mobile Information Device Profile. Like all Java programs, MIDlets are "compile once, run anywhere". To write a MIDlet, you can get Sun's Wireless Toolkit from the Java website, which is available on several platforms and is completely free.
Hints for writing MIDlets:
- Heap sizes can be very small, around 20kb. Therefore, use as few objects as possible and dereference them when they are no longer needed. Also catch OutOfMemoryErrors if you intend to allocate larger amounts of data.
- Programs can not expect more than 8kb persistent storage . Don't keep more than you need.
- Keep in mind that a device can have very different screen dimensions, orientations and color depths. In other words, don't use absolute position.
- Not all devices have keypads or pointers. One should be able to use the program with both. Key layouts may vary too, so use Game Actions for up-down-left-right-action style events.
- Don't white list devices. If the program hasn't been tested on a specific device, assume it works. Never attempt to block the user from trying it.
03-10-2013 05:06:04
The contents of this article is licensed from www.wikipedia.org under the GNU Free Documentation License. Click here to see the transparent copy and copyright details
The contents of this article is licensed from www.wikipedia.org under the GNU Free Documentation License. Click here to see the transparent copy and copyright details


