Current location - Quotes Website - Personality signature - The MANIFEST.MF file under the META-INF folder under the java package has the function of android client
The MANIFEST.MF file under the META-INF folder under the java package has the function of android client

The role of MANIFEST.MF in the META-INF folder:

There is a file in this folder: MANIFEST.MF

Manifest-Version: 1.0< /p>

Ant-Version: Apache Ant 1.7.1

Created-By: 14.0-b16 (Sun Microsystems Inc.)

Main-Class: com.hadeslee. yoyoplayer.player.ui.Main

Class-Path: lib/commons-codec-1.3.jar lib/commons-mons-logging-1.1.jar lib/commons-logging-api.jar lib/examples .j ar lib/jflac-1.2.jar lib/jl1.0.jar lib/jmactritonusspi1.74.jar lib/jn a.jar lib/jogg-0.0.7.jar lib/jorbis-0.0.15.jar lib/ jspeex0.9.7.jar li b/junit-4.4.jar lib/kj_dsp1.1.jar lib/mp3spi1.9.4.jar lib/tritonus_sh are.jar lib/vorbisspi1.0.2.jar

X-COMMENT : Main-Class will be added automatically by build

We classify the configuration information in MANIFEST and can summarize it into the following categories:

1. General attributes

1. Manifest-Version

Used to define the version of the manifest file, for example: Manifest-Version: 1.0

2. Created-By

Declare the generator of the file. Generally, this attribute is generated by the jar command line tool, for example: Created-By: Apache Ant 1.5.1

3. Signature-Version

Definition Signed version of the jar file

4. Class-Path

The application or class loader uses this value to build the internal class search path

2. Application Program-related attributes

1. Main-Class

Define the entry class of the jar file. This class must be an executable class. Once this attribute is defined, you can use java -jar x.jar to run the jar file.

3. Applet related attributes

1. Extension-List

This attribute specifies a list of extended information required by the applet. Each name corresponds to the following attributes

2. -Extension-Name

3. -Specification-Version

4. -Implementation-Version

5. -Implementation-Vendor-Id

5. -Implementation-URL

IV. Extension identification Properties

1. Extension-Name

This property defines the identifier of the jar file, such as Extension-Name: Struts Framework

5. Package extension properties

p>

1. Implementation-Title defines the title of the extension implementation

2. Implementation-Version defines the version of the extension implementation

3. Implementation-Vendor defines the organization of the extension implementation ?

4. Implementation-Vendor-Id defines the identity of the organization that implements the extension

5. Implementation-URL: defines the download address (URL) of the extension package

< p>6. Specification-Title defines the title of the extended specification

7. Specification-Version defines the version of the extended specification

8. Specification-Vendor declares the organization that maintains the specification

p>

9. Sealed defines whether the jar file is sealed, the value can be true or false (I don’t understand this very well)

6. Signature related attributes

Signature aspect For the attributes, we can refer to a section in the mail.jar provided by JavaMail

Name: javax/mail/Address.class

Digest-Algorithms: SHA MD5?

SHA-Digest: AjR7RqnN//cdYGouxbd06mSVfI4=

MD5-Digest: ZnTIQ2aQAtSNIOWXI1pQpw==

This content defines the class name of the class signature, the algorithm name for calculating the digest, and the corresponding Summary content (encoded using BASE64 method)

How should the android client server java files be deployed to tomcat

1. Compile the java program into a .class file and copy it to tomcat The corresponding location in your project.

2. Nowadays, many development tools can easily deploy Java programs to tomcat, such as eclipse

Deploy your project through add and remove, and deploy the project to tomcat through publish. The set location, the default is [drive letter]:\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps