Package org.pentaho.platform.api.engine
Interface IComponent
- All Superinterfaces:
IAuditable
,ILogger
- All Known Subinterfaces:
IDataComponent
,IPreparedComponent
A Component is the smallest module in the platform architecture and represents a unit of work, or an action to
be performed. Different Component implementations provide new channels of functionality as well as multiple
implementations of similar features (.ie, the BIRT Reporting Component and the Jasper Reports Reporting
Component).
-
Field Summary
Fields inherited from interface org.pentaho.platform.api.engine.ILogger
ACTIVITY_LOG, DEBUG, ERROR, FATAL, INFO, INSTANCE_LOG, SESSION_LOG, SOLUTION_LOG, TRACE, UNKNOWN, WARN
-
Method Summary
Modifier and TypeMethodDescriptionvoid
done()
Allows the component to perform any cleanup after the execution of the action.int
execute()
Perform the Component execution; logic for what this Component does goes here.org.pentaho.actionsequence.dom.IActionDefinition
Return the name of the action sequence.org.dom4j.Node
Return the id for the execution of a given action sequence document.boolean
init()
Initialize the Component.void
setActionDefinition
(org.pentaho.actionsequence.dom.IActionDefinition actionDefinition) void
setActionName
(String actionName) void
setComponentDefinition
(org.dom4j.Node componentDefinition) void
setComponentDefinitionMap
(Map<String, String> componentDefinitionMap) void
setInstanceId
(String instanceId) void
setMessages
(List messaes) void
setProcessId
(String processId) void
setRuntimeContext
(IRuntimeContext runtimeContext) void
setSession
(IPentahoSession session) int
validate()
Validate that the Component has all the necessary inputs, outputs and resources it needs to execute successfully.Methods inherited from interface org.pentaho.platform.api.engine.IAuditable
getId, getObjectName
-
Method Details
-
init
boolean init()Initialize the Component. This method is typically called on construction.- Returns:
- returns true if the Component initialized successfully, otherwise returns false
-
validate
int validate()Validate that the Component has all the necessary inputs, outputs and resources it needs to execute successfully. Also may validate a schema here.- Returns:
- one of IRuntimeContext validation conditions
- See Also:
-
execute
int execute()Perform the Component execution; logic for what this Component does goes here.- Returns:
- one of IRuntimeContext execution conditions
- See Also:
-
done
void done()Allows the component to perform any cleanup after the execution of the action. -
setInstanceId
-
getInstanceId
String getInstanceId() -
setActionName
-
getActionName
String getActionName()Description copied from interface:IAuditable
Return the name of the action sequence. Today, that name is synonymous with the name of the action sequence document in the solution repository.- Specified by:
getActionName
in interfaceIAuditable
- Returns:
- the name of the action sequence
-
setProcessId
-
getProcessId
String getProcessId()Description copied from interface:IAuditable
Return the id for the execution of a given action sequence document.- Specified by:
getProcessId
in interfaceIAuditable
- Returns:
- the process id
-
setComponentDefinition
void setComponentDefinition(org.dom4j.Node componentDefinition) -
setComponentDefinitionMap
-
getComponentDefinition
org.dom4j.Node getComponentDefinition() -
setRuntimeContext
-
getRuntimeContext
IRuntimeContext getRuntimeContext() -
setSession
-
getSession
IPentahoSession getSession() -
setMessages
-
getMessages
List getMessages() -
setActionDefinition
void setActionDefinition(org.pentaho.actionsequence.dom.IActionDefinition actionDefinition) -
getActionDefinition
org.pentaho.actionsequence.dom.IActionDefinition getActionDefinition()
-