Functional differences between .class, .jar and .java (class) file in eclipse?

What are the functional differences between a .class file, a .jar file, and a .java file that defines the class structure in eclipse and when is it appropriate to use each file type?

+4
source share
1 answer

The file .javacontains Java code.

File A .classis a .javacompiled file

File A .jaris an executable java package.

Eclipse compiles .javafiles to create files .class, and they can be packaged into an executable file .jar.

+8
source

Source: https://habr.com/ru/post/1542041/


All Articles