Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle Enterprise Scheduler Service
11g Release 1 (11.1.1.6.3)
E26229-05


oracle.as.scheduler.cp.exec
Class ExecutableWrapper

java.lang.Object
  extended by oracle.as.scheduler.cp.exec.ExecutableWrapper

All Implemented Interfaces:
Cancellable, Executable

public class ExecutableWrapper
extends java.lang.Object
implements Executable, Cancellable

This class is used to wrap the program executable to perform certain important tasks before control is handed off to the program executable and after control is returned from it.

This class replaces the program executable class as the ESS executable in the pre-processing phase. When ESS enters the execution stage, it run this class. At this point, this class performs two actions:

This class also implements the Cencellable interface. When cancel() is called on this class, it in turn inspects to see if the underlying program executable implements Cancellable and if yes, invokes it. Else no action is performed.

At the end of the execution, all open resources are closed and control is is returned back to ESS. If an unexpected error occurs during program execution, this error is caught, logged (to the request log file) and re-thrown appropriately.

Version:
$Header: ess/src/oracle/as/scheduler/cp/exec/ExecutableWrapper.java /main/6 2009/05/27 11:36:57 dcraft Exp $

Field Summary
static java.lang.String JAVA_RUNTIME_RESOURCE_BUNDLE_BASE_NAME
          Constant representing the base name of CP Java Runtime Resouce Bundle.
static java.lang.String LOGGER_PREFIX
          The prefix to use when logging messages via ODL.

 

Constructor Summary
ExecutableWrapper()
           

 

Method Summary
 void cancel()
          Implement the cancel() method in the Cancellable interface.
protected  boolean canLog(java.util.logging.Level level)
          Check if log message can be written to the ODL log at a particular level.
 void execute(RequestExecutionContext context, RequestParameters params)
          Implements the execute() method from the Executable interface.
protected  void init()
          Initialize instance variables

 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Field Detail

JAVA_RUNTIME_RESOURCE_BUNDLE_BASE_NAME

public static final java.lang.String JAVA_RUNTIME_RESOURCE_BUNDLE_BASE_NAME
Constant representing the base name of CP Java Runtime Resouce Bundle.
See Also:
Constant Field Values

LOGGER_PREFIX

public static final java.lang.String LOGGER_PREFIX
The prefix to use when logging messages via ODL.
See Also:
Constant Field Values

Constructor Detail

ExecutableWrapper

public ExecutableWrapper()

Method Detail

execute

public void execute(RequestExecutionContext context,
                    RequestParameters params)
             throws ExecutionErrorException,
                    ExecutionWarningException,
                    ExecutionCancelledException,
                    ExecutionPausedException
Implements the execute() method from the Executable interface.
Specified by:
execute in interface Executable
Parameters:
context - the context of the current request
params - the parameters associated with this request
Throws:
ExecutionErrorException - if an error occurs during execution
ExecutionWarningException - if an warning occurs during execution
ExecutionCancelledException - if execution is cancelled by the program for any reason
ExecutionPausedException - if the program logic wants to pause this request
See Also:
State

init

protected void init()
Initialize instance variables

cancel

public void cancel()
Implement the cancel() method in the Cancellable interface.
Specified by:
cancel in interface Cancellable

canLog

protected boolean canLog(java.util.logging.Level level)
Check if log message can be written to the ODL log at a particular level.
Parameters:
level - a Level value
Returns:
a boolean value

Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle Enterprise Scheduler Service
11g Release 1 (11.1.1.6.3)
E26229-05


Copyright © 2008, 2012 Oracle. All rights reserved.