Package net.sourceforge.jnlp.runtime
Class AppletInstance
- java.lang.Object
-
- net.sourceforge.jnlp.runtime.ApplicationInstance
-
- net.sourceforge.jnlp.runtime.AppletInstance
-
public class AppletInstance extends ApplicationInstance
Represents a launched application instance created from a JNLP file. This class does not control the operation of the applet, use the AppletEnvironment class to start and stop the applet.- Version:
- $Revision: 1.9 $
-
-
Field Summary
Fields Modifier and Type Field Description private java.applet.Appletappletthe appletprivate booleanappletStoppedwhether the applet's stop and destroy methods have been calledprivate AppletEnvironmentenvironmentthe applet environmentprivate static LoggerLOG-
Fields inherited from class net.sourceforge.jnlp.runtime.ApplicationInstance
BLACKLIST_FOR_JNLP_PROPERTIES, BLACKLISTED_PROPERTIES_SEPARATOR
-
-
Constructor Summary
Constructors Constructor Description AppletInstance(JNLPFile file, java.lang.ThreadGroup group, JNLPClassLoader loader, java.applet.Applet applet)Create a New Task based on the Specified URLAppletInstance(JNLPFile file, java.lang.ThreadGroup group, JNLPClassLoader loader, java.applet.Applet applet, java.awt.Container cont)Create a New Task based on the Specified URL
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddestroy()Stop the application and destroy its resources.java.applet.AppletgetApplet()AppletEnvironmentgetAppletEnvironment()java.lang.StringgetTitle()Returns the application title.booleanisResizable()voidsetApplet(java.applet.Applet applet)Set the applet of this launched application; can only be called once.voidsetResizable(boolean resizable)Sets whether the applet is resizable or not.-
Methods inherited from class net.sourceforge.jnlp.runtime.ApplicationInstance
addWindow, finalize, getBlackListedJnlpProperties, getClassLoader, getJNLPFile, getMainClassName, getThreadGroup, initialize, isRunning, isSigned
-
-
-
-
Field Detail
-
LOG
private static final Logger LOG
-
appletStopped
private boolean appletStopped
whether the applet's stop and destroy methods have been called
-
applet
private java.applet.Applet applet
the applet
-
environment
private final AppletEnvironment environment
the applet environment
-
-
Constructor Detail
-
AppletInstance
public AppletInstance(JNLPFile file, java.lang.ThreadGroup group, JNLPClassLoader loader, java.applet.Applet applet)
Create a New Task based on the Specified URL- Parameters:
file- pluginbridge to build instance ongroup- thread group of this instanceloader- classloader for this instanceapplet- applet of this instance
-
AppletInstance
public AppletInstance(JNLPFile file, java.lang.ThreadGroup group, JNLPClassLoader loader, java.applet.Applet applet, java.awt.Container cont)
Create a New Task based on the Specified URL- Parameters:
file- pluginbridge to build instance ongroup- thread group of this instanceloader- classloader for this instanceapplet- applet of this instancecont- Container where to place applet
-
-
Method Detail
-
setApplet
public void setApplet(java.applet.Applet applet)
Set the applet of this launched application; can only be called once.- Parameters:
applet- to be set
-
setResizable
public void setResizable(boolean resizable)
Sets whether the applet is resizable or not. Applets default to being not resizable.- Parameters:
resizable- boolean to allow resizing
-
isResizable
public boolean isResizable()
- Returns:
- whether the applet is resizable.
-
getTitle
public java.lang.String getTitle()
Description copied from class:ApplicationInstanceReturns the application title.- Overrides:
getTitlein classApplicationInstance- Returns:
- the application title.
-
getAppletEnvironment
public AppletEnvironment getAppletEnvironment()
- Returns:
- the applet environment.
-
getApplet
public java.applet.Applet getApplet()
- Returns:
- the applet.
-
destroy
public void destroy()
Stop the application and destroy its resources.- Overrides:
destroyin classApplicationInstance
-
-