Class ActionDelegate
- java.lang.Object
-
- org.pentaho.platform.engine.core.system.PentahoBase
-
- org.pentaho.platform.engine.services.PentahoMessenger
-
- org.pentaho.platform.engine.services.solution.ComponentBase
-
- org.pentaho.platform.engine.services.solution.ActionDelegate
-
- All Implemented Interfaces:
Serializable
,org.pentaho.platform.api.engine.IAuditable
,org.pentaho.platform.api.engine.IComponent
,org.pentaho.platform.api.engine.ILogger
,org.pentaho.platform.api.engine.IParameterResolver
public class ActionDelegate extends ComponentBase
The purpose of theActionDelegate
is to represent an action object (which implementsIAction
) as anIComponent
.- See Also:
IAction
, Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected static PropertyNameFormatter
ALTERNATE_INDEX_FORMATTER
protected static PropertyNameFormatter
COMPATIBILITY_FORMATTER
protected static PropertyNameFormatter
STREAM_APPENDER_FORMATTER
-
Fields inherited from class org.pentaho.platform.engine.services.solution.ComponentBase
COMPONENT_EXECUTE_FAIL, debug, MISSING_SESSION, UNKNOWN_COMPONENT_ID
-
Fields inherited from class org.pentaho.platform.engine.core.system.PentahoBase
EMPTYLOGID, loggingLevel, LOGID_MASK1, LOGID_MASK2, LOGID_SEPARATOR
-
-
Constructor Summary
Constructors Constructor Description ActionDelegate(Object actionBean)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
done()
Clean-up should happen in theIAction.execute()
protected boolean
executeAction()
Wires up inputs outputs and resources to an Action and executes it.Object
getActionBean()
org.apache.commons.logging.Log
getLogger()
protected boolean
hasPublicDestination(org.pentaho.actionsequence.dom.IActionOutput contentOutput)
This method will tell you if an output in the action definition references an output stream that has a global/public destination, such as "response", or "content".boolean
init()
Any initialization can be done in theIPreProcessingAction.doPreExecution()
protected boolean
validateAction()
Validation of Action input values should happen in theIAction.execute()
This method is used as a pre execution hook where we setup as much runtime information as possible prior to the actual execute call.protected boolean
validateSystemSettings()
-
Methods inherited from class org.pentaho.platform.engine.services.solution.ComponentBase
addTempParameter, addTempParameterObject, applyInputsToFormat, audit, createFeedbackParameter, createFeedbackParameter, createFeedbackParameter, createFeedbackParameter, createFeedbackParameter, createFeedbackParameter, createFeedbackParameter, createNewInstance, execute, feedbackAllowed, getActionDefinition, getActionName, getActionTitle, getComponentDefinition, getComponentDefinition, getContentOutputItem, getDefaultOutputStream, getFeedbackOutputStream, getId, getInitFailMessage, getInitOk, getInputBooleanValue, getInputLongValue, getInputNames, getInputParameter, getInputStream, getInputStringValue, getInputStringValue, getInputValue, getInstanceId, getLogId, getObjectName, getOutputContentItem, getOutputContentItem, getOutputItem, getOutputItem, getOutputNames, getOutputPreference, getProcessId, getResource, getResourceAsString, getResourceDataSource, getResourceInputStream, getResourceNames, getRuntimeContext, getSession, getSetting, getSolutionName, getSolutionPath, getStringSetting, inputMissingError, isDefinedInput, isDefinedOutput, isDefinedResource, isPromptPending, outputMissingError, promptNeeded, promptNow, resolveParameter, resourceComponentSettingError, resourceMissingError, saveSetting, setActionDefinition, setActionName, setComponentDefinition, setComponentDefinitionMap, setFeedbackMimeType, setInstanceId, setOutputMimeType, setOutputMimeType, setOutputValue, setProcessId, setRuntimeContext, setSession, validate
-
Methods inherited from class org.pentaho.platform.engine.services.PentahoMessenger
debug, debug, error, error, error, fatal, fatal, getMessages, getUserString, info, info, setMessages, trace, trace, warn, warn
-
Methods inherited from class org.pentaho.platform.engine.core.system.PentahoBase
genLogIdFromInfo, genLogIdFromInfo, genLogIdFromSession, getLoggingLevel, setLoggingLevel, setLogId
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
-
-
Field Detail
-
ALTERNATE_INDEX_FORMATTER
protected static final PropertyNameFormatter ALTERNATE_INDEX_FORMATTER
-
COMPATIBILITY_FORMATTER
protected static final PropertyNameFormatter COMPATIBILITY_FORMATTER
-
STREAM_APPENDER_FORMATTER
protected static final PropertyNameFormatter STREAM_APPENDER_FORMATTER
-
-
Constructor Detail
-
ActionDelegate
public ActionDelegate(Object actionBean)
-
-
Method Detail
-
getActionBean
public Object getActionBean()
-
done
public void done()
Clean-up should happen in theIAction.execute()
- Specified by:
done
in interfaceorg.pentaho.platform.api.engine.IComponent
- Specified by:
done
in classComponentBase
-
hasPublicDestination
protected boolean hasPublicDestination(org.pentaho.actionsequence.dom.IActionOutput contentOutput)
This method will tell you if an output in the action definition references an output stream that has a global/public destination, such as "response", or "content". An action definition output is considered thusly, if it has a counterpart of the same name in the action sequence outputs AND that output is of type "content" AND it has declared one or more destinations.- Parameters:
contentOutput
- the action definition output to check- Returns:
- true if this output corresponds to a public destination-bound output
-
executeAction
protected boolean executeAction() throws Throwable
Wires up inputs outputs and resources to an Action and executes it.- Specified by:
executeAction
in classComponentBase
- Throws:
Throwable
-
init
public boolean init()
Any initialization can be done in theIPreProcessingAction.doPreExecution()
- Specified by:
init
in interfaceorg.pentaho.platform.api.engine.IComponent
- Specified by:
init
in classComponentBase
-
validateAction
protected boolean validateAction()
Validation of Action input values should happen in theIAction.execute()
This method is used as a pre execution hook where we setup as much runtime information as possible prior to the actual execute call.- Specified by:
validateAction
in classComponentBase
-
validateSystemSettings
protected boolean validateSystemSettings()
- Specified by:
validateSystemSettings
in classComponentBase
-
getLogger
public org.apache.commons.logging.Log getLogger()
- Specified by:
getLogger
in classPentahoBase
-
-