Mailinglist Archive: opensuse (911 mails)

< Previous Next >
Re: [opensuse] jar file?
A jar file is just a compressed zip file with a content that may make it suitable to be executed as a java program or library.

In general you can uncompress it with general zip tools.

In general if it is a program (containing an executable class file) you could do something like

java -jar filename.jar org.something.package.Classname

to execute the program

if it contains a library then nothing is executable like that, but it has to reside in a classpath. Java classpaths that contain jars must usually be explicitly mentioned, ie. a classpath would explicitly contain the .jar, and not just its containing directory.

There are tools like Ant that automate this process somewhat with things you could call project build files.

Maven is another one, and the third popular one is called Gradle I believe.

Normally you can use a zip tool to see the contents of the file, so perhaps the "Ark" program would also be able to open it.

Regards.



Thomas Taylor schreef op 06-12-2015 16:15:
How does one open and use a *.jar file?

Thanks, Tom KG7CFC

--

Failure seldom stops you. What stops you is the fear of failure.
- Jack Lemmon

^^ --... ...-- / -.- --. --... -.-. ..-. -.-.

^^^^
Tom Taylor KG7CFC
openSUSE 13.1 (64-bit), Kernel 3.11.6-4-default,
KDE 4.11.2, AMD A8-7600, GeForce GTX 740 T/PCIe/
16GB RAM -- 3x1.5TB sata2 -- 128GB-SSD
FF 37.0, claws-mail 3.10.1
registered linux user 263467
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
To contact the owner, e-mail: opensuse+owner@xxxxxxxxxxxx

< Previous Next >
Follow Ups
References