Java Web Start is a deployment based on Java
TM
A new technology for technology applications. It is a convenient channel for connecting to computers and Internet, allowing users to run and manage applications on the Web. Java Web Start provides a simple activation application and ensures that the latest version is always run to eliminate complex installation or upgrade processes. ------ From Sun Java Web Start Release
I think JWS is very simple. Basically, for programmers, there is no extra to learn, as long as I write a jnlp file, I can do a description of my environment:
Tomcat4 Download Address: http://jakarta.apache.org/site/binindex.htmljavaWebStart1.0.1_02 (Build B03) Download address: http://java.sun.com/products/javawebstartjnlp Developer's Pack Download address: http: / /Java.sun.com/products/javawebstart/download-jnlp.html
The following steps for setting up procedures that support JNLP
1. Configure a new Tomcat virtual directory to name myjnlp, create an app, images subdirectory.
2. Write a Myie.java, the function is to enter a URL, you can open this URL. The part of JNLP in the program is rare. The source program is as follows:
Import java.awt. *; import java.awt.event. *; import java.io. *; import java.lang. *; import java.applet. *; import javax.swing. *; import javax.jnlp. * ;
public class MyIE {BasicService bs; JFrame jFrame; TextField tField; Button button; public MyIE () {jFrame = new JFrame ( "MyIE Browser"); tField = new TextField ( "http://www.google.com"); Button = New Button; Container P = jframe.getContentPane (); p.setLayout (); p.Add (Button, BorderLayout.east); P.Add (Tfield, BorderLayout. Center); button.addmouselistener (new mouseadapter () {public void mousepressed (mouseEvent e) {try {bs.showdocument (new java.net.URL (tfield.getText ()));
// Open link} catch (java.net.MalformedURLException exp) {exp.printStackTrace ();}}}); jFrame.addWindowListener (new WindowAdapter () {public void windowClosing (WindowEvent e) {jFrame.setVisible (false); System.exit (0);}}); jframe.pack (); jframe.setsize (400, 80); jframe.setvisible (TRUE);
Try {bs = (BasicService) ServiceManager.lookup ("javax.jnlp.basicservice); // finds the basic service interface of JNLP.} catch (unavailableServiceExcection e) {bs = null;} catch (exception e) { E.PrintStackTrace ();}} public static void main (string args []) {myie myie = new myie ();}}
3. Write a JNLP file named myie.jnlp (or other, but at the end of JNLP), this is a descriptive file. XML Version = "1.0" Encoding = "UTF-8"?>
4. Compile MYIE.JAVA (JNLP.jar in JNLP Developer's Pack;)
5. Package the generated class file to myie.jar and save myie.jar to the app directory.
6. Create a list.html file, save it to the app directory.
7. 1> Start your Tomcat Access List.html, click Myie connection to run. 2> Start your javawebstart, in its file ----> Preferences menu ---> Advanced ----> Delete the join in the application URL text box. I am http: // liaoyuan: 8080 / myjnlp / app / list.html, press OK, click the remote application to see myie, It can be run.
I only use a little JNLP thing. He also has some services such as accessing local files, printing, etc. Can refer to JNLP Developer's Pack. Doubtful place Welcome to the letter to discuss zlyperson@163.net