Explain how to convert Java file to jar files?
- Java Archive (JAR) files is a platform-independent file which allows to compress add bundle multiple files associated with the java application, appletsor webstart application in a single file.
Some of the functions provided by JAR files are as follows:1. Data compression.
2. Ease of distribution.
3. Authentication.
The following is the process:Type jar –cvf <jarfilename.jar> <.java file(s)>
- Where c stands for create, v stands for verbose and f indicates the file follows it, into which the archive to be stored. <.java file(s)> is the Java files that are to be placed in the .jar file.