ScriptingResource

public class ScriptingResource extends AbstractCaosDBServerResource

Methods

callScript

public int callScript(Form form, List<FileProperties> files)

callScript

public int callScript(List<String> commandLine, Integer timeoutMs, List<FileProperties> files)

callScript

public int callScript(List<String> commandLine, Integer timeoutMs, List<FileProperties> files, Object authToken)

checkExecutionPermission

public void checkExecutionPermission(Subject user, String call)

form2CommandLine

public List<String> form2CommandLine(Form form)

generateAuthToken

public Object generateAuthToken(String call)

Generate and return a token for the purpose of the given call. If the user is not anonymous and the call is not configured to be called by everyone, a SessionToken is returned instead.

generateRootElement

public Element generateRootElement(ServerSideScriptingCaller caller)

getLogger

public Logger getLogger()

handleForm

public int handleForm(Form form)

handleMultiparts

public int handleMultiparts(Representation entity)

httpGetInChildClass

protected Representation httpGetInChildClass()

httpPostInChildClass

protected Representation httpPostInChildClass(Representation entity)

Handles a POST request to server-side scripting.

Parameters:
  • entity – Representation of the request.

isAnonymous

public boolean isAnonymous()