public interface ScriptingScript extends ScriptingText, ScriptingBaseScript, Script
Interface that represents a single script without window dialog.
ScriptingUnit
,
ScriptingBaseScript
ISOLATION_HIGH, ISOLATION_LOW
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getCode()
Returns the ScriptingScript's code.
|
java.lang.String |
getLangName()
Returns the languange in which the ScriptingScript is written.
|
java.lang.String |
getMainName()
Returns the name of the main function in the ScriptingScript's code
|
java.lang.String |
getMimeType() |
java.lang.Object |
invokeFunction(java.lang.String name,
java.lang.Object[] args)
Executes a function from the Script's code
|
java.lang.Object |
invokeMethod(java.lang.Object obj,
java.lang.String name,
java.lang.Object[] args)
Executes a method from the Script's code
|
void |
registerDataFolder(java.lang.String id) |
void |
save()
Persists the current status of a ScriptingScript with the content associated.
|
void |
setCode(java.lang.String code)
Sets a the code associated with a ScriptingScript.
|
void |
setMainName(java.lang.String mainName)
Stablishes a new main main function in the ScriptingScript's code.
|
getText, setText
addStderrWriter, addStdoutWriter, compile, getIsolationGroup, getLibrarySuffix, getResource, getScriptFile, isEnabled, put, removeStderrWriter, removeStdoutWriter, run, run, runAsTask, setEnabled, setIsolationGroup, setLibrarySuffix
addPropertyChangeListener, getCreatedBy, getDescription, getFile, getFileResource, getFiles, getIconNames, getId, getName, getParent, getProperties, getProperty, getTypeName, getUserPath, getVersion, isASystemUnit, isSaved, move, reload, remove, rename, setCreatedBy, setDescription, setName, setProperty, setSaved, setVersion
addObserver, deleteObserver, deleteObservers
java.lang.String getLangName()
java.lang.String getCode()
void setCode(java.lang.String code)
java.lang.String getMainName()
void setMainName(java.lang.String mainName)
mainName
- String that contains the new main function name.void save()
save
in interface ScriptingText
java.lang.Object invokeMethod(java.lang.Object obj, java.lang.String name, java.lang.Object[] args) throws java.lang.NoSuchMethodException
obj
- this Object represents the script's codename
- method's name to executeargs
- input parameters of the methodjava.lang.NoSuchMethodException
- If there isn't a main function to begin the executionjava.lang.Object invokeFunction(java.lang.String name, java.lang.Object[] args) throws java.lang.NoSuchMethodException
invokeFunction
in interface Script
name
- method's name to executeargs
- input parameters of the methodjava.lang.NoSuchMethodException
- If there isn't a main function to begin the executionjava.lang.String getMimeType()
getMimeType
in interface ScriptingText
void registerDataFolder(java.lang.String id)