View Javadoc

1   /*
2    * @(#) DSOLApplet.java Nov 5, 2003
3    * 
4    * Copyright (c) 2002-2005 Delft University of Technology Jaffalaan 5, 2628 BX
5    * Delft, the Netherlands. All rights reserved.
6    * 
7    * This software is proprietary information of Delft University of Technology
8    * The code is published under the Lesser General Public License
9    */
10  package nl.tudelft.simulation.dsol.gui.applets;
11  
12  import javax.swing.JApplet;
13  
14  import nl.tudelft.simulation.dsol.gui.DSOLApplication;
15  import nl.tudelft.simulation.language.io.URLResource;
16  
17  /***
18   * @author peter
19   */
20  public class DSOLApplet extends JApplet
21  {
22  	/***
23  	 * constructs a new DSOLApplet
24  	 */
25  	public DSOLApplet()
26  	{
27  		super();
28  	}
29  
30  	/***
31  	 * @see java.applet.Applet#init()
32  	 */
33  	public void init()
34  	{
35  		super.init();
36  		String navigation = this.getParameter("navigation");
37  		if (navigation == null)
38  		{
39  			navigation = "/navigation.xml";
40  		}
41  		new DSOLApplication(URLResource.getResource(navigation));
42  	}
43  
44  	/***
45  	 * @see java.lang.Object#finalize()
46  	 */
47  	protected void finalize() throws Throwable
48  	{
49  		this.stop();
50  		super.finalize();
51  	}
52  }