Java jar File

Source: Internet
Author: User

The JAR (Java Archive) is a file format based on the zip file format.

It is used to bundle Java applications or applets of resources, class files, sound files, images, etc. It also provides data compression. A jar file as a special type of zip file. The contents of the jar file can be digitally signed to provide security. It provides a platform-independent file format.

You can use the Jar API to process jar files in a Java program. Jar files can have optional META-INF directories to contain the files and directories that contain application configuration information.

Meta-inf Directory

The following table lists the META-INF entries in the directory.

name type Purpose
MANIFEST. Mf File It contains extensions and packet-related data.
INDEX. LIST File It contains the location information for the package. The class loader uses it to speed up the class search and load process.
X.sf File X is the base file name. It stores the signature of the jar file.
X.dsa File X is the base file name. It stores the digital signature of the corresponding signature file.
/services Directory This directory contains all the service provider configuration files.
jar Tool

The JDK provides a jar tool to create and manipulate jar files. You can also use java.util.jar the classes in the package to create and manipulate jar files using the Java API.

The JAR API has some new classes to work with the manifest file. Manifestclass represents a manifest file. jarmany command-line options are available to create jar files using tools.
The following code lists the jar tool's command-line options.

Click on the link to view the details

Java jar File

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.