MIDlets must be packaged in JAR files for delivery to mobile devices. A JAR file is a compressed archive file that can be opened with most file compression applications, including WinZip. Eclipse and NetBeans create JAR files automatically during the building/deployment process. A JAR file contains several types of files:
The compiled Java .class files.
Other resources (video, audio, images) placed in the res subdirectory.
A plain text MANIFEST.MF placed in META-INF subdirectory.
For internet distribution, the MIME-type application/java-archive must
be set in the web server for JAR files.
MANIFEST.MF files have a similar function as the
JAD files described below and both are required for proper MIDlet deployment.
A MANIFEST.MF file contains meta-information about the
MIDlet, such as version number and MIDlet name. The function and attributes
of MANIFEST.MF are described in the table JAD
and MANIFEST.MF parameters.