Community articleAbout MIME Types
Added by IBM contributorIBM on July 26, 2013
Rate this article 1 starsRate this article 2 starsRate this article 3 starsRate this article 4 starsRate this article 5 stars

JAR files that are enclosed in forms must have the MIME type set to:
  • application/uwi_jar
The corresponding XFDL code will look like this:

If you are using the Designer to enclose a JAR file into a form the Designer will set the MIME type for you.
You can also override the default Java Virtual Machine (JVM) that is used to run the enclosed JAR file. To do this, you must add a vm parameter to your MIME type, as shown:
      application/uwi-jar; vm="<java virtual machine>"

Set this to the string that the JVM uses to register itself. For example,"Sun VM <version>". The version is guaranteed to include a major and minor number, and may include further information, such as a maintenance number, build number, and so on.
Since it can be difficult to get an exact match, you can use the * wildcard in the version string. For example, you might use the following string:
   Sun VM 1.4*

This will match any version beginning with 1.4, such as “1.4.2_03 JDK” or “1.4 JDK”.
When there are multiple matches, the API will default to the latest version. For example, if you search for version 1.4*, and you have “Sun VM 1.4 JDK” and “Sun VM 1.4.2_03 JDK” installed, the API will use version 1.4.2_03.
Additionally, the API always chooses the JDK over the JRE. For example, if you search for version 1.4*, and you have “Sun VM 1.4.2_03 JDK” and “Sun VM 1.4.2_03 JVM” installed, the API will use the JDK.