Java software can be released in several ways, depending on the target market.
The simplest for the developer (but the most difficult for the end user) is simply to issue a jar file (or a set of Jar files). In many systems, the JAR will be a “double-click” and thus will be executed. But if the end user does not have Java installed, this will not work.
It’s good if you control the target environment. It’s also good if you want to target Windows, Mac, and Linux right away. Any Java platform can run it, including platforms that you have not considered.
It’s bad if you focus on ordinary users. He cannot "set tasks", configure anything on the Start menu, or associate himself with a file type.
Java Web Start is my preference in most cases. It provides a Java-based installer and can customize the start menu, associate file types and all that stuff. But it creates a security window during installation.
Good for most cases. You have only one link for all OS.
It is bad if you suspect that the user does not have the JRE installed, or you do not want the end user to know that the application is written in Java.
You can free the zip file using the Jars in and the .bat file and the .sh file to gain access.
Good for administrators, developers, and command line applications.
Bad for end users who really don't know what a bat and shell script are, and had no idea what to do if the script was broken for their system.
Thin .exe wrapper around the Jar file. This gives end users the impression that the application is native. They usually come with ...
A installer with Java support . This is a native installer (therefore different installers for Windows, Mac, and Linux). This will determine if Java is installed on the target machine, and if the JRE fails to start. He will also be able to perform all the interesting functions after installation, such as establishing file associations and adding items to the start menu.
Good for most cases. It’s bad if you are targeting multi-level platforms, since you will need to maintain an installer for each platform. It is also bad if one of the target platforms does not have a Java installer installed (then you will need to use the other methods above for this platform).
Source exe . Using the Java-to-native compiler (Jet, GCJ or IKVM), you create your own executable file.
Well, if you really do not want people to know that you are using Java, or you need to integrate with your native environment for some time (ikvm will allow you to use your Java code in .NET as just a .NET object).
It’s bad, because people think that it will magically make the application faster when it isn’t.
A jpm4j . JPM is a package manager for Java, such as npm for nodejs. This allows you to install the software through a small command line script, for example, to install jython you can use jpm install -f --name jython org.python:jython . Good for developer tools. Bad for end users as it is command line based and requires them to install jpm first.
Edit: IKVM, jpm