|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object abbot.script.Step abbot.script.Call abbot.script.Launch abbot.script.Appletviewer
public class Appletviewer
Provides applet launch capability. Usage:
<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.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class abbot.script.Launch |
---|
Launch.ThreadedLaunchListener |
Field Summary |
---|
Fields inherited from interface abbot.script.XMLConstants |
---|
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 Summary | |
---|---|
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. |
Method Summary | |
---|---|
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). |
Methods inherited from class abbot.script.Launch |
---|
createClassLoader, equivalent, getClasspath, getHierarchy, getMethod, getTarget, getTargetClass, isLaunched, isThreaded, launch, resolveClass, setClasspath, setThreaded, setThreadedLaunchListener, synchronizedRunStep |
Methods inherited from class abbot.script.Call |
---|
disambiguateMethod, evaluateParameter, evaluateParameters, getArgs, getArguments, getArgumentsDescription, getEncodedArguments, getMethodName, getMethods, getTargetClassName, invoke, resolveMethod, resolveMethods, setArguments, setArguments |
Methods inherited from class abbot.script.Step |
---|
addAttributes, addContent, createAttributeMap, createStep, createStep, getDescription, getResolver, parseStepAttributes, resolveTester, run, setDescription, setScriptError, simpleClassName, toEditableString, toString, toXML, toXMLString, usage, usage |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Appletviewer(Resolver resolver, Map attributes)
public Appletviewer(Resolver resolver, String description, String code, Map params, String codebase, String archive, String classpath)
Method Detail |
---|
protected void quitApplet(Frame frame)
public void runStep() throws Throwable
runStep
in class Launch
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)
protected Map parseParams(String attribute)
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
getUsage
in class Launch
public String getXMLTag()
Step
getXMLTag
in class Launch
public ClassLoader getContextClassLoader()
getContextClassLoader
in interface UIContext
getContextClassLoader
in class Launch
ClassLoader
providing access to classes in this
context.protected void install()
Launch
install
in class Launch
protected boolean removeSMOnExit()
protected Frame getFrame()
public void terminate()
terminate
in interface UIContext
terminate
in class Launch
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |