public class Appletviewer extends Launch
<applet code="..." [codebase="..."] [params="..."]
[archive="..."]>
The attributes are equivalent to those provided in the HTML
applet
tag. The params
attribute is a
comma-separated list of name=value
pairs, which will be passed
to the applet within the applet
tag as param
elements.
WARNING: Closing the appletviewer window from the window manager
close button will result applet-spawned event dispatch threads being left
running. To avoid this situation, always use the appletviewer Quit
menu item or use the terminate()
method of this class.
Launch.ThreadedLaunchListener
TAG_ACTION, TAG_APPLETVIEWER, TAG_ARCHIVE, TAG_ARGS, TAG_ASSERT, TAG_AWT, TAG_AWTTESTSCRIPT, TAG_BORDER_TITLE, TAG_CALL, TAG_CLASS, TAG_CLASSPATH, TAG_CODE, TAG_CODEBASE, TAG_COMMENT, TAG_COMPONENT, TAG_COUNT, TAG_DELEGATE, TAG_DESC, TAG_DOCBASE, TAG_EVENT, TAG_EXPR, TAG_FILENAME, TAG_FIXTURE, TAG_FORKED, TAG_HEIGHT, TAG_HORDER, TAG_ICON, TAG_ID, TAG_INDEX, TAG_INVERT, TAG_INVOKER, TAG_KEYCHAR, TAG_KEYCODE, TAG_KIND, TAG_LABEL, TAG_LAUNCH, TAG_METHOD, TAG_MODIFIERS, TAG_NAME, TAG_PARAMS, TAG_PARENT, TAG_POLL_INTERVAL, TAG_PROPERTY, TAG_ROOT, TAG_SAMPLE, TAG_SCRIPT, TAG_SEQUENCE, TAG_SLOW, TAG_STOP_ON_ERROR, TAG_STOP_ON_FAILURE, TAG_TAG, TAG_TERMINATE, TAG_TEXT, TAG_THREADED, TAG_TIMEOUT, TAG_TITLE, TAG_TRIGGER, TAG_TYPE, TAG_VALUE, TAG_VMARGS, TAG_VORDER, TAG_WAIT, TAG_WEIGHTED, TAG_WIDTH, TAG_WINDOW, TAG_X, TAG_Y
Constructor and Description |
---|
Appletviewer(Resolver resolver,
Map attributes)
Create an applet-launching step.
|
Appletviewer(Resolver resolver,
String description,
String code,
Map params,
String codebase,
String archive,
String classpath)
Create an applet-launching step.
|
Modifier and Type | Method and Description |
---|---|
protected String |
generateHTML()
Generate HTML suitable for launching this applet.
|
String |
getArchive() |
Map |
getAttributes()
Attributes to save in script.
|
String |
getCode() |
String |
getCodebase() |
ClassLoader |
getContextClassLoader()
Returns the applet class loader.
|
String |
getDefaultDescription()
Return a reasonable default description for this script step.
|
protected Frame |
getFrame() |
String |
getHeight() |
Map |
getParams() |
String[] |
getParamsAsArray() |
String |
getParamsAttribute() |
String |
getUsage()
Provide a usage String for this step.
|
String |
getWidth() |
String |
getXMLTag()
Define the XML tag to use for this script step.
|
protected void |
install()
Install the class loader context for the code being launched.
|
protected Map |
parseParams(String attribute) |
protected void |
quitApplet(Frame frame) |
protected boolean |
removeSMOnExit() |
void |
runStep()
Run this step.
|
void |
setArchive(String archive) |
void |
setCode(String code) |
void |
setCodebase(String codebase) |
void |
setHeight(String height) |
void |
setMethodName(String name) |
void |
setParams(Map params) |
void |
setTargetClassName(String name) |
void |
setWidth(String width) |
void |
terminate()
To properly terminate, we need to invoke AppletViewer's appletQuit()
method (protected, but accessible).
|
createClassLoader, equivalent, getClasspath, getHierarchy, getMethod, getTarget, getTargetClass, isLaunched, isThreaded, launch, resolveClass, setClasspath, setThreaded, setThreadedLaunchListener, synchronizedRunStep
disambiguateMethod, evaluateParameter, evaluateParameters, getArgs, getArguments, getArgumentsDescription, getEncodedArguments, getMethodName, getMethods, getTargetClassName, invoke, resolveMethod, resolveMethods, setArguments, setArguments
addAttributes, addContent, createAttributeMap, createStep, createStep, getDescription, getResolver, parseAttributes, resolveTester, run, setDescription, setScriptError, simpleClassName, toEditableString, toString, toXML, toXMLString, usage, usage
public Appletviewer(Resolver resolver, Map attributes)
protected void quitApplet(Frame frame)
public void runStep() throws Throwable
protected String generateHTML()
public void setTargetClassName(String name)
setTargetClassName
in class Call
public void setMethodName(String name)
setMethodName
in class Call
public void setCode(String code)
public String getCode()
public void setCodebase(String codebase)
public String getCodebase()
public void setArchive(String archive)
public String getArchive()
public String getWidth()
public void setWidth(String width)
public String getHeight()
public void setHeight(String height)
public Map getParams()
public void setParams(Map params)
public String[] getParamsAsArray()
public String getParamsAttribute()
public Map getAttributes()
Call
getAttributes
in class Launch
public String getDefaultDescription()
Step
getDefaultDescription
in class Launch
public String getUsage()
Step
public String getXMLTag()
Step
public ClassLoader getContextClassLoader()
getContextClassLoader
in interface UIContext
getContextClassLoader
in class Launch
ClassLoader
providing access to classes in this
context.protected void install()
Launch
protected boolean removeSMOnExit()
protected Frame getFrame()
Abbot is hosted on