<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.3.2" -->
<rss version="0.92">
<channel>
	<title>J2ME Codes</title>
	<link>http://j2me-codes.inhandlearning.com</link>
	<description>J2ME Source Code Examples, sample, midlet, multimedia, rms, video, graphics, game</description>
	<lastBuildDate>Thu, 11 Jun 2009 03:29:34 +0000</lastBuildDate>
	<docs>http://backend.userland.com/rss092</docs>
	<language>en</language>
	
	<item>
		<title>Google Translate API in JavaME (J2ME)</title>
		<description>Google Translate API in JavaME (J2ME)
J2ME users now can instantly use Google Translator using a simple API to use Google Translate in JavaME (J2ME) platform. It uses the Google AJAX Language API to do the translation via a HTTP connection.

Requirements: CLDC-1.1 MIDP-1.0

To Install it, simply include the google-api-translate-javame.jar file in ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=43</link>
			</item>
	<item>
		<title>J2ME Encryption with Bouncy Castle</title>
		<description>import org.bouncycastle.crypto.*;import org.bouncycastle.crypto.engines.*;import org.bouncycastle.crypto.modes.*;import org.bouncycastle.crypto.params.*;public class Encryptor {private BufferedBlockCipher cipher;private KeyParameter key;// inisialisasi engine kriptografi.// array key paling sedikit 8 bytes.public Encryptor( byte[] key ){cipher = new PaddedBlockCipher(new CBCBlockCipher(new DESEngine() ) );this.key = new KeyParameter( key );}// inisialisasi engine kriptografi.// string paling sedikit 8 chars.public Encryptor( String key ){this( key.getBytes() ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=41</link>
			</item>
	<item>
		<title>View PNG Image with Thread</title>
		<description>   /*--------------------------------------------------     * ViewPngThread.java     *     * Download and view a png file. The download is     * done in the background with a separate thread      *   ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=40</link>
			</item>
	<item>
		<title>Canvas for processing game actions</title>
		<description>/*--------------------------------------------------* GameActions.java** Canvas for processing game actions** Example from the book:     Core J2ME Technology* Copyright John W. Muchow   http://www.CoreJ2ME.com* You may use/modify for any non-commercial purpose*-------------------------------------------------*/  import javax.microedition.midlet.*;import javax.microedition.lcdui.*;public class GameActions extends MIDlet{  private Display  display;      ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=39</link>
			</item>
	<item>
		<title>Display Alert</title>
		<description>//jad file (please verify the jar size)/*MIDlet-Name: DisplayAlertMIDlet-Version: 1.0MIDlet-Vendor: MyCompanyMIDlet-Jar-URL: DisplayAlert.jarMIDlet-1: DisplayAlert, , DisplayAlertMicroEdition-Configuration: CLDC-1.0MicroEdition-Profile: MIDP-1.0MIDlet-JAR-SIZE: 100*/import javax.microedition.lcdui.Alert;import javax.microedition.lcdui.AlertType;import javax.microedition.lcdui.Command;import javax.microedition.lcdui.CommandListener;import javax.microedition.lcdui.Display;import javax.microedition.lcdui.Displayable;import javax.microedition.lcdui.Form;import javax.microedition.midlet.MIDlet;import javax.microedition.midlet.MIDletStateChangeException;public class DisplayAlert extends MIDlet implements CommandListener {  private Display display;  private Alert alert;  private Form form = new Form("Throw Exception");  ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=38</link>
			</item>
	<item>
		<title>Accessing Commands</title>
		<description>/*--------------------------------------------------* AccessingCommands.java** Example from the book:     Core J2ME Technology* Copyright John W. Muchow   http://www.CoreJ2ME.com* You may use/modify for any non-commercial purpose*-------------------------------------------------*/import javax.microedition.midlet.*;import javax.microedition.lcdui.*;public class AccessingCommands extends MIDlet implements CommandListener{  private Display display;      // Reference to Display object  ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=37</link>
			</item>
	<item>
		<title>Sample of graphics, commands, and event handling.</title>
		<description>/* * @(#)Sample.java  1.9 01/06/08 * Copyright (c) 1999-2001 Sun Microsystems, Inc. All Rights Reserved. */import javax.microedition.midlet.*;import javax.microedition.lcdui.*;/* * A quick sample of graphics,  commands, and event handling. */public class SampleCanvasMIDlet extends MIDlet implements CommandListener {    Display display;    Command exitCommand;   ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=36</link>
			</item>
	<item>
		<title>Thread Example in J2ME</title>
		<description>/*
J2ME: The Complete Reference

James Keogh

Publisher: McGraw-Hill

ISBN 0072227109

*/
// jad file (Please verify the jar size first)
/*
MIDlet-Name: BackgroundProcessing
MIDlet-Version: 1.0
MIDlet-Vendor: MyCompany
MIDlet-Jar-URL: BackgroundProcessing.jar
MIDlet-1: BackgroundProcessing, , BackgroundProcessing
MicroEdition-Configuration: CLDC-1.0
MicroEdition-Profile: MIDP-1.0
MIDlet-JAR-SIZE: 100

*/
import javax.microedition.midlet.*;
import javax.microedition.lcdui.*;
import javax.microedition.io.*;
import java.io.*;

public class BackgroundProcessing extends MIDlet
implements CommandListener
{
private Display display;
private Form form;
private Command exit;
private Command start;
public BackgroundProcessing()
{
display = Display.getDisplay(this);
form = new Form("Background Processing");
exit = ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=35</link>
			</item>
	<item>
		<title>Storing Image into RMS</title>
		<description>import javax.microedition.lcdui.*;
import javax.microedition.midlet.MIDlet;
import javax.microedition.rms.*;
import java.io.*;

public class ImageStore extends MIDlet  implements CommandListener {

private Command CmdExit;
private Command CmdOpen;
private Command CmdBack;
private Command CmdSave;
private Display display;
RecordStore rStore;
Form form = null;
Image image = null;
InputStream is =null;

public ImageStore() {

rStore = null;

display = Display.getDisplay(this);

CmdExit = new Command("Exit", 1, 2);
CmdOpen = new Command("Show", 1, 3);
CmdBack = new ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=34</link>
			</item>
	<item>
		<title>Animation Midlet</title>
		<description>/*J2ME in a NutshellBy Kim TopleyISBN: 0-596-00253-X*/import java.util.Timer;import java.util.TimerTask;import javax.microedition.lcdui.Canvas;import javax.microedition.lcdui.Command;import javax.microedition.lcdui.CommandListener;import javax.microedition.lcdui.Display;import javax.microedition.lcdui.Displayable;import javax.microedition.lcdui.Form;import javax.microedition.lcdui.Gauge;import javax.microedition.lcdui.Graphics;import javax.microedition.lcdui.Item;import javax.microedition.lcdui.ItemStateListener;import javax.microedition.midlet.MIDlet;public class AnimationMIDlet extends MIDlet                         implements CommandListener, ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=33</link>
			</item>
	<item>
		<title>Multiple ChoiceGroup</title>
		<description>/*--------------------------------------------------* MultipleChoiceGroup.java** Example from the book:     Core J2ME Technology* Copyright John W. Muchow   http://www.CoreJ2ME.com* You may use/modify for any non-commercial purpose*-------------------------------------------------*/import javax.microedition.midlet.*;import javax.microedition.lcdui.*;public class MultipleChoiceGroup extends MIDlet implements ItemStateListener, CommandListener{  private Display display;      // Reference to display object ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=32</link>
			</item>
	<item>
		<title>ChoiceGroup With Image</title>
		<description>/*--------------------------------------------------* ChoiceGroupWithImages.java** Example from the book:     Core J2ME Technology* Copyright John W. Muchow   http://www.CoreJ2ME.com* You may use/modify for any non-commercial purpose*-------------------------------------------------*/import javax.microedition.midlet.*;import javax.microedition.lcdui.*;public class ChoiceGroupWithImages extends MIDlet implements CommandListener{  private Display display;      // Reference to display object  ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=31</link>
			</item>
	<item>
		<title>GUI Test in Midlet</title>
		<description>/*Learning Wireless JavaHelp for New J2ME DevelopersBy Qusay MahmoudISBN: 0-596-00243-2*/import javax.microedition.lcdui.*;import javax.microedition.midlet.*;public class GuiTests extends MIDlet implements CommandListener {    // display manager    Display display = null;        // a menu with items    List menu = ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=30</link>
			</item>
	<item>
		<title>TextBox Capture</title>
		<description>/*J2ME: The Complete ReferenceJames KeoghPublisher: McGraw-HillISBN 0072227109*///jad file (please verify the jar size)/*MIDlet-Name: TextBoxCaptureMIDlet-Version: 1.0MIDlet-Vendor: MyCompanyMIDlet-Jar-URL: TextBoxCapture.jarMIDlet-1: TextBoxCapture, , TextBoxCaptureMicroEdition-Configuration: CLDC-1.0MicroEdition-Profile: MIDP-1.0MIDlet-JAR-SIZE: 100*/import javax.microedition.midlet.*;import javax.microedition.lcdui.*;public class TextBoxCapture extends MIDlet implements CommandListener{  private Display display;   private TextBox textbox;   private Command submit;   private Command exit; ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=29</link>
			</item>
	<item>
		<title>TextField Capture</title>
		<description>//jad file (please verify the jar size)/*MIDlet-Name: TextFieldCaptureMIDlet-Version: 1.0MIDlet-Vendor: MyCompanyMIDlet-Jar-URL: TextFieldCapture.jarMIDlet-1: TextFieldCapture, , TextFieldCaptureMicroEdition-Configuration: CLDC-1.0MicroEdition-Profile: MIDP-1.0MIDlet-JAR-SIZE: 100*/import javax.microedition.lcdui.Command;import javax.microedition.lcdui.CommandListener;import javax.microedition.lcdui.Display;import javax.microedition.lcdui.Displayable;import javax.microedition.lcdui.Form;import javax.microedition.lcdui.TextField;import javax.microedition.midlet.MIDlet;public class TextFieldCapture extends MIDlet implements CommandListener {  private Display display;  private Form form = new Form("Sign In Please");  private Command submit = new ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=28</link>
			</item>
	<item>
		<title>Basic RMS Example</title>
		<description>import javax.microedition.midlet.*;import javax.microedition.lcdui.*;import javax.microedition.rms.*;import java.io.*;public class RMSDemo extends MIDlet implements CommandListener {        private Display display;    private RecordStore rs=null;    private Command exit;    private RecordEnumeration re;    private int recordNO;    Form ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=27</link>
			</item>
	<item>
		<title>Font Demo J2ME</title>
		<description>The Font class represents fonts and font metrics. Fonts cannot be created by applications. The setFont(Font font) method of graphic class sets the font for all subsequent text rendering operations. And there is no call to showNotify and hideNotify method on some the device. This application will help game developer ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=26</link>
			</item>
	<item>
		<title>Capturing Video with J2ME</title>
		<description>Illustration below takes pictures on a J2ME device.import java.io.IOException;import javax.microedition.lcdui.*;import javax.microedition.media.*;import javax.microedition.media.control.*;import javax.microedition.midlet.MIDlet;import javax.microedition.media.control.VideoControl;public class VideoMIDlet extends MIDlet implements CommandListener {        private Display display;    private Form form;    private Command exit,back,capture,camera;    private Player player;  ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=25</link>
			</item>
	<item>
		<title>Vibrate Phone</title>
		<description>You can make your phone migrate in J2ME by calling vibrate(int duration) method of javax.microedition.lcdui.Display class. The duration parameter is the number of milliseconds the vibrator should be run.Display.getDisplay(this).vibrate(800); </description>
		<link>http://j2me-codes.inhandlearning.com/?p=24</link>
			</item>
	<item>
		<title>Playing local MP3</title>
		<description>The method below creates player and play mp3 file.public void run(){  try  {    InputStream is = getClass().getResourceAsStream("/your.mp3");    player = Manager.createPlayer(is,"audio/mpeg");    player.realize();    // get volume control for player and set volume to max    vc ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=23</link>
			</item>
	<item>
		<title>Playing Video</title>
		<description>MMAPI(Mobile Media API) provides a framework for playing media content on J2ME devices.There are protocols defined for real-time streaming of Internet radio content, streaming other RTP (Real-time Transport Protocol) content, capturing audio, and taking pictures.The method below plays a video file the on mobile device:public void run(){  try  ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=22</link>
			</item>
	<item>
		<title>Play Sound in midlet</title>
		<description>javax.microedition.media package is introduced in MIDP2.0 profile. This package supports sound and upward compatibility with MultiMedia API.It has Manager, Player and Control as main objects.Different audio files, from various locations can be played on mobile.Simple Media Playback  try  {     Player p = Manager.createPlayer("http://webserver/music.wav");  ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=21</link>
			</item>
	<item>
		<title>Implement a textbox in a mobile game</title>
		<description>import java.io.InputStream;import java.io.InputStreamReader;import java.io.IOException;import javax.microedition.lcdui.Display;import javax.microedition.lcdui.TextBox;import javax.microedition.lcdui.TextField;import javax.microedition.lcdui.Ticker;import javax.microedition.midlet.MIDlet;public class TextBoxMIDlet extends MIDlet {        // Maximum size of the text in the TextBox    private static final int MAX_TEXT_SIZE = 64;        // The TextBox ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=20</link>
			</item>
	<item>
		<title>J2ME Networking:Interacting Server PHP(Image Fetch)</title>
		<description>You can even retrieve binary data such as images.  If the mobile device is capable of view documents like word or PDF then you should be able to send those by HTTP as well.J2ME Source Code:import javax.microedition.midlet.*;import javax.microedition.lcdui.*;import javax.microedition.io.*;import java.io.*;public class SimpleImageFetch extends MIDlet{  private Display display;  ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=19</link>
			</item>
	<item>
		<title>J2ME Networking:Connect Server PHP(HTTP GET)</title>
		<description>Here is an example invoking PHP with GET parameters:J2ME Source Code:import java.io.*;import javax.microedition.io.*;import javax.microedition.lcdui.*;import javax.microedition.midlet.*;public class SimpleGETExample extends MIDlet {    private Display display;    String url = "http://127.0.0.1/midlet/testGET.php?type=2";    public SimpleGETExample() {       display = Display.getDisplay(this);   ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=18</link>
			</item>
	<item>
		<title>Simple demo of using timers</title>
		<description>import java.util.*;import javax.microedition.midlet.*;import javax.microedition.lcdui.*;public class TimerMidlet extends MIDlet implements CommandListener{  private Display display;   private Form form;         private Command exit;      private Command stop;      private Timer timer;     ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=17</link>
			</item>
	<item>
		<title>A utility of startTimer</title>
		<description>// Starts a timer to run a simple taskprivate void startTimer( ) {        // Create a task to be run    task = new TimerTask( ) {               ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=16</link>
			</item>
	<item>
		<title>A MIDlet with Hello text and an Exit command</title>
		<description>/* * * Copyright (c) 2000 Sun Microsystems, Inc. All Rights Reserved. * * This software is the confidential and proprietary information of Sun * Microsystems, Inc. ("Confidential Information").  You shall not * disclose such Confidential Information and shall use it only in * accordance with the terms of ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=15</link>
			</item>
	<item>
		<title>Sort mixed records in RMS</title>
		<description>/*J2ME: The Complete ReferenceJames KeoghPublisher: McGraw-HillISBN 0072227109*///jad file (please verify the jar size)/*MIDlet-Name: SortMixedRecordDataTypeExampleMIDlet-Version: 1.0MIDlet-Vendor: MyCompanyMIDlet-Jar-URL: SortMixedRecordDataTypeExample.jarMIDlet-1: SortMixedRecordDataTypeExample, ,           SortMixedRecordDataTypeExampleMicroEdition-Configuration: CLDC-1.0MicroEdition-Profile: MIDP-1.0MIDlet-JAR-SIZE: 100*/import javax.microedition.rms.*;import javax.microedition.midlet.*;import javax.microedition.lcdui.*;import java.io.*;public class SortMixedRecordDataTypeExample          extends MIDlet ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=14</link>
			</item>
	<item>
		<title>How to search a simple record in RMS</title>
		<description>/*J2ME: The Complete ReferenceJames KeoghPublisher: McGraw-HillISBN 0072227109*/// jad file (Please verify the jar size first)/*MIDlet-Name: SearchExampleMIDlet-Version: 1.0MIDlet-Vendor: MyCompanyMIDlet-Jar-URL: SearchExample.jarMIDlet-1: SearchExample, , SearchExampleMicroEdition-Configuration: CLDC-1.0MicroEdition-Profile: MIDP-1.0MIDlet-JAR-SIZE: 100*/import javax.microedition.rms.*;import javax.microedition.midlet.*;import javax.microedition.lcdui.*;import java.io.*;public class SearchExample extends MIDlet implements CommandListener{  private Display display;  private Alert alert;  private Form form;   private ...</description>
		<link>http://j2me-codes.inhandlearning.com/?p=13</link>
			</item>
</channel>
</rss>
