public abstract class ScriptHandler extends Object
Modifier and Type | Class and Description |
---|---|
static class |
ScriptHandler.ScriptException |
Modifier and Type | Field and Description |
---|---|
static int |
ACTIVITY_CHANGE
The activity change reason.
|
static int |
ACTIVITY_CLICK
The activity click reason.
|
static int |
ACTIVITY_DOCCLOSE
The activity do close reason.
|
static int |
ACTIVITY_DOCREADY
The activity doc ready reason.
|
static int |
ACTIVITY_ENTER
The activity enter reason.
|
static int |
ACTIVITY_EXIT
The activity exit reason.
|
static int |
ACTIVITY_FULL
The activity full reason.
|
static int |
ACTIVITY_INDEXCHANGE
The activity index change reason.
|
static int |
ACTIVITY_INITIALIZE
An activity initialize script reason.
|
static int |
ACTIVITY_MOUSEDOWN
The activity mouse down reason.
|
static int |
ACTIVITY_MOUSEENTER
The activity mouse enter reason.
|
static int |
ACTIVITY_MOUSEEXIT
The activity mouse exit reason.
|
static int |
ACTIVITY_MOUSEUP
The activity mouse up reason.
|
static int |
ACTIVITY_POSTEXECUTE
The activity post-execute reason.
|
static int |
ACTIVITY_POSTOPEN
The activity post-open reason.
|
static int |
ACTIVITY_POSTPRINT
The activity post-print reason.
|
static int |
ACTIVITY_POSTSAVE
The activity post-save reason.
|
static int |
ACTIVITY_POSTSIGN
The activity post-sign reason.
|
static int |
ACTIVITY_POSTSUBMIT
The activity post-submit reason.
|
static int |
ACTIVITY_PREEXECUTE
The activity pre-execute reason.
|
static int |
ACTIVITY_PREOPEN
The activity pre-open reason.
|
static int |
ACTIVITY_PREPRINT
The activity pre-print reason.
|
static int |
ACTIVITY_PRESAVE
An activity pre-save script reason.
|
static int |
ACTIVITY_PRESIGN
The activity pre-sign reason.
|
static int |
ACTIVITY_PRESUBMIT
The activity pre-submit reason.
|
static int |
ACTIVITY_READY
The activity ready reason.
|
static int |
ACTIVITY_VALIDATIONSTATE
The activity validation state reason.
|
static int |
BP_CLEAR |
static int |
BP_SET |
static int |
BREAK |
static int |
CALCULATE
The calculate script reason.
|
static int |
ERR_BadBreakContinue |
static int |
ERR_FuncBuiltIn |
static int |
ERR_FuncUnknown |
static int |
ERR_OK |
static int |
ERR_Syntax |
static int |
executeReason_LAST |
static int |
FEATURE_CAN_BREAK |
static int |
FEATURE_CAN_HALT |
static int |
FEATURE_CAN_SET_BREAKPOINT |
static int |
FEATURE_CAN_STEP_INTO |
static int |
FEATURE_CAN_STEP_OUT |
static int |
FEATURE_CAN_STEP_OVER |
static int |
FEATURE_IS_REMOTE |
static int |
FEATURE_NONE |
static int |
HALT |
static int |
ObjectInteraction_End |
static int |
ObjectInteraction_Start |
static int |
PREDICATE
The predicate (when executing a predicate in a SOM expression) reason.
|
static int |
STEP_INTO |
static int |
STEP_OUT |
static int |
STEP_OVER |
static int |
UNSPECIFIED
The unspecified script reason.
|
static int |
VALIDATE
The validate script reason.
|
Constructor and Description |
---|
ScriptHandler()
Instantiates a script handler.
|
ScriptHandler(ScriptDebugger oDebugger)
Instantiates a script handler using the given debugger.
|
Modifier and Type | Method and Description |
---|---|
abstract ScriptHandler |
clone()
Clones this script handler.
|
static ScriptHandler |
createScriptHandler(String contentType,
AppModel appModel,
ScriptDebugger debugger)
Deprecated.
This won't work in client environments.
|
boolean |
debugBreakPoint(int nScriptID,
int nLine,
int eSetType)
Set or clear a break-point.
|
boolean |
debugCommand(int eCmd)
Set an internal flag in the script handler indicating that, when control
is returned to the script handler, it should perform a step-over,
step-into or step-out function (calling the stopped callback on the
associated debugger).
|
boolean |
debugGetStack(List<String> oStack)
Get the current stack frame.
|
boolean |
debugGetVariables(List<String> oVarNames,
List<Arg> oVarValues)
Retrieve parallel lists of variable names and their values (lists have
the same size).
|
void |
execute(String script,
String locale,
Arg returnValue,
int eReason)
Executes the given script.
|
abstract void |
executeOrSyntaxCheck(String script,
Arg oReturnValue,
int eReason,
boolean bSyntaxCheckOnly)
Executes or checks the syntax of the given script.
|
static String |
executeReasonToString(int eReason)
Converts an executeReason into a string.
|
static int |
executeReasonToXFAEnum(int eReason)
Converts an executeReason into an XFAEnum.
|
ScriptDebugger |
getDebugger()
Get the debugger for this script handler.
|
String |
getOption(String sOptionName)
Gets the value of the given option.
|
abstract String |
languageName()
Gets the name of the scripting language supported by this script handler.
|
void |
removeReference(Node oNode)
Removes any script references to the node and the descendants
|
void |
setDebugger(ScriptDebugger oDebugger)
Set the debugger for this script handler.
|
void |
setOption(String sOptionName,
String sOptionValue)
Sets the value of the given option.
|
static int |
stringToExecuteReason(String sReason)
Converts a string into an executeReason.
|
void |
syntaxCheck(String script)
Checks the given script for syntax errors.
|
boolean |
wasFatalError()
Determines the severity of an error is returned from execute().
|
public static final int UNSPECIFIED
public static final int CALCULATE
public static final int VALIDATE
public static final int ACTIVITY_INITIALIZE
public static final int ACTIVITY_PRESAVE
public static final int ACTIVITY_POSTSAVE
public static final int ACTIVITY_PREPRINT
public static final int ACTIVITY_POSTPRINT
public static final int ACTIVITY_READY
public static final int ACTIVITY_DOCREADY
public static final int ACTIVITY_DOCCLOSE
public static final int ACTIVITY_PRESUBMIT
public static final int ACTIVITY_PREEXECUTE
public static final int ACTIVITY_POSTEXECUTE
public static final int ACTIVITY_PREOPEN
public static final int ACTIVITY_INDEXCHANGE
public static final int PREDICATE
public static final int ACTIVITY_PRESIGN
public static final int ACTIVITY_POSTSIGN
public static final int ACTIVITY_POSTSUBMIT
public static final int ACTIVITY_POSTOPEN
public static final int ACTIVITY_VALIDATIONSTATE
public static final int ObjectInteraction_Start
public static final int ACTIVITY_ENTER
public static final int ACTIVITY_EXIT
public static final int ACTIVITY_MOUSEENTER
public static final int ACTIVITY_MOUSEEXIT
public static final int ACTIVITY_CHANGE
public static final int ACTIVITY_CLICK
public static final int ACTIVITY_FULL
public static final int ACTIVITY_MOUSEUP
public static final int ACTIVITY_MOUSEDOWN
public static final int ObjectInteraction_End
public static final int executeReason_LAST
public static final int ERR_OK
public static final int ERR_Syntax
public static final int ERR_BadBreakContinue
public static final int ERR_FuncBuiltIn
public static final int ERR_FuncUnknown
public static final int STEP_OVER
public static final int STEP_INTO
public static final int STEP_OUT
public static final int BREAK
public static final int HALT
public static final int BP_SET
public static final int BP_CLEAR
public static final int FEATURE_NONE
public static final int FEATURE_IS_REMOTE
public static final int FEATURE_CAN_SET_BREAKPOINT
public static final int FEATURE_CAN_STEP_OVER
public static final int FEATURE_CAN_STEP_INTO
public static final int FEATURE_CAN_STEP_OUT
public static final int FEATURE_CAN_BREAK
public static final int FEATURE_CAN_HALT
public ScriptHandler()
public ScriptHandler(ScriptDebugger oDebugger)
oDebugger
- a script debugger.public static ScriptHandler createScriptHandler(String contentType, AppModel appModel, ScriptDebugger debugger)
contentType
- the contentType of the script.appModel
- the AppModel that contains the context for the script.debugger
- the ScriptDebugger for debugging the script, or null if debugging is not required.ExFull
- if the contentType is not recognized.public void setDebugger(ScriptDebugger oDebugger)
public abstract void executeOrSyntaxCheck(String script, Arg oReturnValue, int eReason, boolean bSyntaxCheckOnly)
script
- the script to execute.oReturnValue
- the return value of the script.eReason
- the reason for the execution of the script.bSyntaxCheckOnly
- the flag to only check syntax when set.ExFull
- whenever errors are reported.public void execute(String script, String locale, Arg returnValue, int eReason)
script
- the script to execute.locale
- the operating locale.returnValue
- the return value of the script.eReason
- the reason for the execution of the script.ExFull
- whenever errors are reported.public void syntaxCheck(String script)
script
- the script to execute.ScriptHandler.ScriptException
- upon syntax error. ScriptException derives from ExFull.public abstract String languageName()
public void setOption(String sOptionName, String sOptionValue)
sOptionName
- the name of the option to set.sOptionValue
- the value to set.public String getOption(String sOptionName)
sOptionName
- the name of the option to get.public boolean wasFatalError()
public abstract ScriptHandler clone()
public static int stringToExecuteReason(String sReason)
public static String executeReasonToString(int eReason)
public static int executeReasonToXFAEnum(int eReason)
public ScriptDebugger getDebugger()
public boolean debugCommand(int eCmd)
public boolean debugBreakPoint(int nScriptID, int nLine, int eSetType)
public boolean debugGetVariables(List<String> oVarNames, List<Arg> oVarValues)
public void removeReference(Node oNode)
Copyright © 2010 - 2020 Adobe. All Rights Reserved