mobile tech2009 j2me
TRANSCRIPT
-
8/6/2019 Mobile Tech2009 J2ME
1/18
Arsitektur J2ME
Untuk fleksibilitas, arsitektur J2ME
menggunakan kategori untuk Konfigurasi dan
profile
Configuration
Connected Device Configuration (CDC)
Connected Limited Device Configuration (CLDC)
MIDP layer: The Mobile Information Device
Profile (MIDP)
-
8/6/2019 Mobile Tech2009 J2ME
2/18
Arsitektur J2ME
-
8/6/2019 Mobile Tech2009 J2ME
3/18
Configuration
Mendefiniskan lingkungan run-time dasar
sebagai suatu himpunan/set kelas inti (core
class) dan JVM spesifik yang dapat berjalan di
tipe perangkat tertentu.
Terdapat 2 jenis Configuration yang ada :
CLDC (Connected Limited Device Configuration)
CDC (Connected Device Configuration)
-
8/6/2019 Mobile Tech2009 J2ME
4/18
CLDC
is used specifically with the KVM for 16-bit or
32-bit devices with limited amounts of
memory.
This is the configuration (and the virtual
machine) used for developing small J2ME
applications.
-
8/6/2019 Mobile Tech2009 J2ME
5/18
CLDC
Target devices for J2ME applications developedusing CLDC generally have the followingcharacteristics:
160 to 512 kilobytes of total memory available forthe Java platform
Limited power, often battery powered
Network connectivity, often with a wireless,
inconsistent connection and with limitedbandwidth
User interfaces with varying degrees ofsophistication; sometimes with no interface at all
-
8/6/2019 Mobile Tech2009 J2ME
6/18
CLDC
CLDC defines the following requirements:
Full Java language support (except for floating
pointer support, finalization, and error handling)
Full JVM support
Security for CLDC
Limited internationalization support
Inherited classes -- all classes not specific to CLDC
must be subsets of J2SE 1.3 classes
-
8/6/2019 Mobile Tech2009 J2ME
7/18
CLDC
Classes specific to CLDC are in
javax.microedition package and subpackages
-
8/6/2019 Mobile Tech2009 J2ME
8/18
CDC
is used with the C virtual machine (CVM) and
is used for 32-bit architectures requiring more
than 2 MB of memory
-
8/6/2019 Mobile Tech2009 J2ME
9/18
CDC
Connected Device Configuration (CDC) has been
defined as a stripped-down version of Java 2
Standard Edition (J2SE) with the CLDC classes
added to it. Therefore, CDC was built upon
CLDC, and as such, applications developed for
CLDC devices also run on CDC devices.
-
8/6/2019 Mobile Tech2009 J2ME
10/18
CDC
According to Sun Microsystems, target devices forCDC generally have the following characteristics:
Powered by a 32-bit processor
Two megabytes or more of total memoryavailable for the Java platform
Network connectivity, often with a wireless,inconsistent connection and with limited
bandwidth User interfaces with varying degrees of
sophistication; sometimes with no interface
-
8/6/2019 Mobile Tech2009 J2ME
11/18
Profile
The profile defines the type of devicessupported by your application. Specifically, itadds domain-specific classes to the J2ME
configuration to define certain uses fordevices.
Profiles are built on top of configurations. Twoprofiles have been defined for J2ME and arebuilt on CLDC: KJava and Mobile InformationDevice Profile (MIDP).
-
8/6/2019 Mobile Tech2009 J2ME
12/18
Profile
Two profiles have been defined for J2ME and are builtupon CLDC: KJava and MIDP
Profile 1: KJava
KJava is Sun's proprietary profile and contains theKJava API. The KJava profile is built on top of the CLDCconfiguration. The KJava virtual machine, KVM, acceptsthe same byte codes and class file format as the classicJ2SE virtual machine.
The KJava API has a great deal in common with theJ2SE Abstract Windowing Toolkit (AWT).
Because it is not a standard J2ME package, its mainpackage is com.sun.kjava.
-
8/6/2019 Mobile Tech2009 J2ME
13/18
Profile
MIDP contains the following packages, the firstthree of which are core CLDC packages, plusthree MIDP-specific packages:
* java.lang* java.io
* java.util
* javax.microedition.io
* javax.microedition.lcdui* javax.microedition.midlet
* javax.microedition.rms
-
8/6/2019 Mobile Tech2009 J2ME
14/18
Profile
Profile 2: MIDP
The MIDP, like KJava, is built upon CLDC and
provides a standard run-time environment that
allows new applications and services to be
deployed dynamically on end-user devices.
MIDP is a common, industry-standard profile for
mobile devices that is not dependent on aspecific vendor. It is a complete and supported
foundation for mobile application development.
-
8/6/2019 Mobile Tech2009 J2ME
15/18
CLDC - CDC
-
8/6/2019 Mobile Tech2009 J2ME
16/18
Design considerations for small
devices Keep it simple
Smaller is better.
Minimize run-time memory use.
-
8/6/2019 Mobile Tech2009 J2ME
17/18
Memainkan Suara
Menggunakan package
javax.microedition.media.Manager;
javax.microedition.media.MediaException; javax.microedition.media.Player;
-
8/6/2019 Mobile Tech2009 J2ME
18/18
Tipe file suara
Audio wav "audio/x-wav";
Jts: "audio/x-tone-seq";
Midi "audio/midi";