Java Reference
In-Depth Information
A JAD descriptor file consists of readable text including name-value pairs describing properties of
its associated Java application. Each line of the descriptor file holds one attribute, where an
attribute consists of a name and a value, separated by a colon. The following attribute describes
the file size of the application JAR file:
Jar-File-Size: 2123
The application developer is responsible for maintaining the JAD and JAR files. Additionally, the
descriptor file and the associated JAR file must be placed on the same Web site.
JAM on MIDP
Whereas the CLDC JAM specification is relatively vague, MIDP contains a concrete definition of
the JAD files for MIDP applications. This section first takes a closer look at the contents of a JAD
file, and then describes the actual transfer of an MIDP application to the target device. However,
before we go into details of the JAD files, we need to explain the MIDP concept of MIDlet suites.
MIDlet Suites
A MIDlet suite is a set of Java applications distributed together. A group of MIDlets inside a
MIDlet suite can share their persistent databases. For example, a database might consist of user
logins that are used by all network-related MIDlets in one suite.
Since MIDP devices offer only a limited amount of heap space for the Java Runtime Environment,
it may make sense to split application functionality into two or more MIDlets. For instance, one
MIDlet of a suite could be responsible for providing a user interface for entering application data.
A second MIDlet in the same suite could be responsible for synchronizing the data with a remote
server over the Internet. Both MIDlets would access the same data stored in a persistent database
accessible from all MIDlets of the suite.
MIDP JAD Files
JAD files have already been defined in general CLDC terms. MIDP extends the specification with
respect to the special requirements of mobile information devices. The JAD file in MIDP consists
of mandatory and optional attributes. The application provider must fill the mandatory attributes
 
Search WWH ::




Custom Search