| META TOPICPARENT | name="JavaWebStart" |
<-- This creates the navigation links to : Home | Help | Index | etc. -->
JAR <-- this automatically adds a header showing the name of this page -->
<-- Your Javapedia article goes here. Please try to include at least one sentence describing this topic. -->
<-- Also please try to include at least one sentence describing where each link goes. -->
<-- Please make sure some other page points to your new article so that others can find it! -->
<-- For more on how to write Javapedia articles please read the WritingArticles page. -->
JAR stands for Java Archive. It contains Java class files and a manifest which provides meta-information. Jar files are the standard way to distribute Java libraries, applets, and applications. They are compressed using zip.
The Java tutorial has information on how to use Jars.
To create a jar file:
- use the jar program included in every Java JDK.
- use the jar task for Apache Ant.
- use WinZip or any other zip compression utility.
- use Java! The Java runtime includes powerful zip and jar tools. It is possible to create a Java program or servlet that jars classes when executed. A constructed JAR file could be useful for Applets.
Sometimes a JAR file is not appropriate for distributing a Java application. All of these formats are similar to Jar, but with a different purpose:
- Web applications are distributed as WAR files, which include classes and servlets, JSP and HTML pages, and meta-information in XML.
- Enterprise applications are distributed as EAR files.
- Services are distributed as SAR files.
<-- put two horizontal ruled lines between article and discussion of it. -->
<-- anchor to allow a link to the discussion about this article -->
Discussion about JAR <-- generate a header for the discussion part of page --> |