Sunday, May 20, 2018

Define Jar,War,Ear file Interview Questions

Leave a Comment

What is Jar,War and Ear in Java




What is EAR file

Enterprise Archive file. A JAR archive that contains a J2EE application.

What is JAR file

Java Archive file it contains a J2EE application.

You can create a JAR file using the command

jar cf XYZ.jar *.class *.gif

if will compress all the .class files and the related gif files to the one file called jar

You can extract the JAR file using the command

jar xf XYZ.jar

Updating the existing JAR file

jar -uf XYZ.jar file1.class

What is WAR file

Enterprise Archive file. A JAR archive that contains a J2EE application.

You can create a WAR file using the command

jar -cfv XYZ.war
You can extract a WAR file using the command

jar -xfv XYZ.war
If You Enjoyed This, Take 5 Seconds To Share It

0 comments:

Post a Comment