Java Web Start Sample Applications

The Java Web Start product is a deployment solution for Java-technology-based applications. It is the plumbing between the computer and the Internet that allows the user to launch and manage applications right off the Web. Java Web Start provides easy, one-click activation of applications, and guarantees that you are always running the latest version of the application, eliminating complicated installation or upgrade procedures. Furthermore, the Java Web Start product can be used to manage the Java platform versions on which applications run.

Java Web Start technology enables web deployment by leveraging existing Internet protocols -- applications are launched when a client accesses, typically by clicking on a link in an HTML page, a special launch file with a .jnlp filename extension.

Java Web Start technology is built on the Java Network and Launching Protocol (JNLP) API. The JNLP API provides services that enable applications to obtain information not normally available using the Java 2 Platform, Standard Edition (J2SE) platform API. Such services include access to the system clipboard, control over resource caching, ability to import files from a local disk (even in a restricted execution environment), and many others.

Net-based applications can use the JNLP API to get the full benefit offered from Java Web Start technology. The download available below contains source code for sample applications that demonstrate various features of Java Web Start technology and the JNLP API. These working examples will help to introduce you to Java Web Start technology and the JNLP API, and the concepts illustrated in the examples should provide guidance to help you implement your own full-featured applications on the Web.

Descriptions of Sample Applications

The following are brief descriptions of the sample applications in the download bundle. Each application is contained in a separate directory in the download, and each application/directory contains a readme file with more information about the application, including build instructions.

CORBA

This sample demonstrates how an application that uses CORBA can be packaged, downloaded and executed as a JNLP application by Java Web Start. RMI-IIOP utilizes the Java CORBA Object Request Broker (ORB) and the Internet InterORB Protocol (IIOP), so you can write all of your code in the Java programming language, and use the rmic compiler to generate the code necessary for connecting your applications via IIOP to others written in any CORBA-compliant language.

Extension Installer

This sample demonstrates features of JNLP's ExtensionInstallerService API. It is an extension installer which uses the ExtensionInstallerService interface to communicate with the client. Java Web Start, upon encountering an extension tag in the .jnlp file, starts the specified extension installer class. The extension installer application writes a native shared library (libinst.so or inst.dll) to the recommended directory on the local client machine. It then informs the JNLP client of the directory where it should search for native libraries.

Library Installer

This sample demonstrates usage of the <nativelib> element in a .jnlp file. A <nativelib> element specifies a JAR file that contains native libraries.

Random Access File

This sample demonstrates features of JNLP's JNLPRandomAccessFile API. A user-selected file is opened as a random file for both writing and reading. The application first writes hard coded strings to the file smf then reads whatever was written and displays it to the screen using standard AWT Container and the TextArea components.

WebPad Application

This simple word processing application allows users to create, open, modify, save and print files.

Download Sample Applications

License Agreement:

Any use or implementation of this sample source code is subject to this License agreement.

Download

More Information

Visit here to learn more about the Java Web Start product.