RedwoodScript Scripting Contexts and Implicit Objects

Scripting contexts are fields in which scripting with RedwoodScript may be used. The implicit objects provided differ between the contexts.

RedwoodScript Contexts

This section lists the implicit objects available.

AlertEscalationPostAlertAction

Name Class Description
jcsAlertEscalationPostAlertContext AlertEscalationPostAlertActionScriptObject The alert escalation action context
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.

AlertSourcePostAlertAction

Name Class Description
jcsAlertSourcePostAlertContext AlertSourcePostAlertActionScriptObject The alert source action context
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.

EmailAlertGatewayPreSendAction

Name Class Description
jcsEmailAlertGatewayPreSendActionContext EmailAlertGatewayPreSendActionScriptObject The email alert gateway presend action context
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.

ExtensionPoint

Name Class Description
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsExtensionPointContext ExtensionPointScriptObject The Extension Point context
jcsOutLog Logger Standard out logger.
jcsParameters ExtensionParameters Helper object to get access to the parameters in the request
jcsRequest ExtensionPointHttpServletRequest The request object containing all information about the request made by the user
jcsResponse ExtensionPointHttpServletResponse A response object used to send information back to the user
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.
jcsUserSession SchedulerSession A scheduler session based on the user executing the action

ImportAction

Name Class Description
jcsErrLog Logger Standard error logger.
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsImportRuleSet ImportActionScriptObject The import action context
jcsJobContext UserJobContext Job context for user defined jobs.
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.
jcsTargetPartition Partition The (optional) target partition passed to the import

JobFileAccessTrigger

Name Class Description
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsFileAccessMethod JobFileAccessMethod The access method being called
jcsJobFile JobFile The job file being requested
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.
jcsSubject Subject The subject of the callee
jcsTriggerContext TriggerScriptObject The trigger context
jcsUserSession SchedulerSession A scheduler session based on the user executing the action

NativeJavaJob

Name Class Description
jcsErr PrintWriter Standard error.
jcsErrLog Logger Standard error logger.
jcsJobContext NativeJavaJobContext jcsNativeJobContext.description
jcsJobId Long jcsNativeJobId.description
jcsOut PrintWriter Standard out.
jcsOutLog Logger Standard out logger.

ObjectDefinitionChangeTrigger

Name Class Description
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.
jcsTriggerContext TriggerScriptObject The trigger context

OnBeforeObjectDefinitionChangeTypeAction

Name Class Description
jcsBeforeDefinitionChangeContext OnBeforeObjectDefinitionChangeTypeActionScriptObject The before definition change context
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.

OnBeforeUserJobChangeAction

Name Class Description
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsJob Job Object representing the current job.
jcsOnBeforeUserChangeContext OnBeforeUserJobChangeActionScriptObject The on before user process change context
jcsOut PrintWriter Standard out.
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.
jcsUserSession SchedulerSession A scheduler session based on the user executing the action

OnChangeAction

Name Class Description
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsJob Job Object representing the current job.
jcsOnChangeContext PreExecutingActionScriptObject The on change context
jcsOut PrintWriter Standard out.
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.

OnUserMessageOperationAction

Name Class Description
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsJob Job Object representing the current job.
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.
jcsUserMessageOperationContext OnUserMessageOperationActionScriptObject The on user operation context

PeriodFunction

Name Class Description
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.

PostRunningAction

Name Class Description
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsJob Job Object representing the current job.
jcsOut PrintWriter Standard out.
jcsOutLog Logger Standard out logger.
jcsPostRunningContext PostRunningActionScriptObject The post running context
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.

PreRunningAction

Name Class Description
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsJob Job Object representing the current job.
jcsOut PrintWriter Standard out.
jcsOutLog Logger Standard out logger.
jcsPreRunningContext PreExecutingActionScriptObject The pre running context
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.

ScriptJob

Name Class Description
jcsErr PrintWriter Standard error.
jcsErrLog Logger Standard error logger.
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsJob Job Object representing the current job.
jcsJobContext UserJobContext Job context for user defined jobs.
jcsOut PrintWriter Standard out.
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.

Shell

Name Class Description
jcsErr PrintWriter Standard error.
jcsErrLog Logger Standard error logger.
jcsExecutorContext ExecutorContext jcsExecutorContext.description
jcsJob Job Object representing the current job.
jcsOut PrintWriter Standard out.
jcsOutLog Logger Standard out logger.
jcsSession SchedulerSession Central interface for retrieving and creating all of the Scheduler objects. You must set the ActionSubject in some contexts to be able to access the SchedulerSession.
jcsShell Shell A shell

Using RedwoodScript in Objects

Object Topic
Jobs RedwoodScript in Jobs
Queues RedwoodScript in Queues
Process Servers RedwoodScript in Process Servers