Web start and JNLP demo : JNLP Web Start « Network Protocol « Java






Web start and JNLP demo

Web start and JNLP demo
 
/*
<?xml version="1.0" encoding="UTF-8"?>
<jnlp spec="1.0+"
 codebase="file:///c:/"
 href="start.jnlp">
<information>
 <title>JNLP Test</title>
 <vendor>Java Source and Support, Inc.</vendor>
 <homepage href="http://www.java2s.com" />
 <description>Demonstration of JNLP</description>
</information>
<resources>
 <j2se version="1.2+" />
 <jar href="JNLPTest.jar"/>
</resources>
<application-desc main-class="JNLPTest" />
</jnlp>


*/

import java.awt.BorderLayout;
import java.awt.Container;

import javax.swing.JFrame;
import javax.swing.JLabel;

public class JNLPTest {
  public static void main(String args[]) {
    JFrame frame = new JFrame();
    Container content = frame.getContentPane();
    JLabel label = new JLabel("Hello, JNLP");
    content.add(label, BorderLayout.CENTER);
    frame.setSize(200, 200);
    frame.show();
    try {
      Thread.sleep(5000);
    } catch (InterruptedException ignored) {
    } finally {
      System.exit(0);
    }
  }
}


           
         
  








Related examples in the same category

1.Java Web Start: File Chooser Demo Project
2.Java Web Start Demo
3.JNLP Demo
4.JNLP Download Servlet
5.This sample is the Java Web Start JRE auto-download installer
6.This sample demonstrates features of the JNLPRandomAccessFile API
7.Webpad: word processing application allows users to Create, Open, Modify, Save and Print files
8.This sample demonstrates on how to use CORBA within Java Web Start
9.Hello Java Web start
10.JNLP-based applet launcher class for deploying applets that use extension libraries containing native code.