DynamicTreeDemo.jar - JavaWS and JNLP Demo

Q

How to run the JavaWS and JNLP demo, DynamicTreeDemo.jar?

✍: FYIcenter

A

DynamicTreeDemo.jar is an application provided by Oracle to demonstrate how to use JavaWS and JNLP. Here are steps on how to run the DynamicTreeDemo.jar with JavaWS command.

1. Copy and save the following JNLP file, dynamictree.jnlp, to \fyicenter folder:

<?xml version="1.0" encoding="utf-8"?>
<!-- 
/*
 * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved.
 */ 
-->

<jnlp spec="1.0+" 
   codebase="https://docs.oracle.com/javase/tutorialJWS/samples/deployment/dynamictree_webstartJWSProject"
   href="dynamictree_webstart.jnlp">
   <information>
      <title>Dynamic Tree Demo</title>
      <vendor>Dynamic Team</vendor>
   </information>
   <resources>
      <j2se version="1.7+"
          href="http://java.sun.com/products/autodl/j2se"/>
      <jar href="DynamicTreeDemo.jar" main="true" />
   </resources>
   <application-desc
       name="Dynamic Tree Demo Application"
       main-class="webstartComponentArch.DynamicTreeApplication">
   </application-desc>
   <update check="background"/>
</jnlp>

Run JavaWS command in a command window:

>\fyicenter\jdk-1.8.0\bin\javaws dynamictree.jnlp

JavaWS will download the DynamicTreeDemo.jar file given in the JNLP file, dynamictree.jnlp, and launch it.

When DynamicTreeDemo.jar is running, you see a new window the demo application showing a tree of nodes:
JavaWS and JNLP Demo Application: DynamicTreeDemo.jar

 

Introduction of JavaWS and JNLP

⇒⇒FAQ for JavaWS (Java Web Start)

2018-01-13, 399👍, 0💬