public class ComponentImplementationExample extends Object implements IComponent
Modifier and Type | Field and Description |
---|---|
protected static boolean |
debug |
String |
EMPTYLOGID |
protected int |
loggingLevel |
static String |
LOGID_MASK1 |
static String |
LOGID_MASK2 |
static String |
LOGID_SEPARATOR |
ACTIVITY_LOG, DEBUG, ERROR, FATAL, INFO, INSTANCE_LOG, SESSION_LOG, SOLUTION_LOG, TRACE, UNKNOWN, WARN
Constructor and Description |
---|
ComponentImplementationExample() |
Modifier and Type | Method and Description |
---|---|
protected String |
applyInputsToFormat(String format) |
protected void |
audit(String messageType,
String message,
String value,
int duration) |
protected void |
createFeedbackParameter(IActionParameter actionParam) |
protected void |
createFeedbackParameter(ISelectionMapper selMap,
String fieldName,
Object defaultValues) |
void |
createFeedbackParameter(String fieldName,
String displayName,
String hint,
Object defaultValues,
List values,
Map dispNames,
String displayStyle) |
protected void |
createFeedbackParameter(String fieldName,
String displayName,
String hint,
String defaultValue,
boolean visible) |
String |
createNewInstance(boolean persisted,
Map parameters,
boolean forceImmediateWrite) |
void |
debug(String message) |
void |
debug(String message,
Throwable error) |
void |
done() |
void |
error(String message) |
void |
error(String message,
Throwable error) |
int |
execute() |
protected boolean |
executeAction() |
void |
fatal(String message) |
void |
fatal(String message,
Throwable error) |
protected boolean |
feedbackAllowed() |
void |
genLogIdFromInfo(String sessId,
String procId,
String actName) |
void |
genLogIdFromInfo(String sessId,
String procId,
String actName,
String instId) |
void |
genLogIdFromSession(IPentahoSession sess) |
org.pentaho.actionsequence.dom.IActionDefinition |
getActionDefinition() |
String |
getActionName() |
String |
getActionTitle() |
org.dom4j.Node |
getComponentDefinition() |
protected OutputStream |
getDefaultOutputStream(String mimeType) |
protected OutputStream |
getFeedbackOutputStream() |
String |
getId() |
String |
getInitFailMessage() |
boolean |
getInitOk() |
protected boolean |
getInputBooleanValue(String inputName,
boolean defaultValue) |
protected long |
getInputLongValue(String inputName,
long defaultValue) |
protected Set |
getInputNames() |
protected IActionParameter |
getInputParameter(String parameterName) |
protected InputStream |
getInputStream(String inputName) |
protected String |
getInputStringValue(String inputName) |
protected Object |
getInputValue(String inputName) |
String |
getInstanceId() |
org.apache.commons.logging.Log |
getLogger() |
int |
getLoggingLevel() |
String |
getLogId() |
List |
getMessages() |
String |
getObjectName() |
protected IContentItem |
getOutputContentItem(String mimeType) |
protected IContentItem |
getOutputContentItem(String outputName,
String mimeType) |
protected IActionParameter |
getOutputItem(String outputName) |
protected IContentItem |
getOutputItem(String outputName,
String mimeType,
String extension) |
protected Set |
getOutputNames() |
protected int |
getOutputPreference() |
String |
getProcessId() |
protected IActionSequenceResource |
getResource(String resourceName) |
String |
getResourceAsString(IActionSequenceResource resource) |
protected org.pentaho.commons.connection.IPentahoStreamSource |
getResourceDataSource(IActionSequenceResource resource) |
protected InputStream |
getResourceInputStream(IActionSequenceResource resource) |
protected Set |
getResourceNames() |
IRuntimeContext |
getRuntimeContext() |
IPentahoSession |
getSession() |
protected Object |
getSetting(String name) |
protected String |
getSolutionName() |
protected String |
getSolutionPath() |
protected String |
getStringSetting(String name) |
static String |
getUserString(String type) |
void |
info(String message) |
void |
info(String message,
Throwable error) |
boolean |
init() |
void |
inputMissingError(String paramName) |
protected boolean |
isDefinedInput(String inputName) |
protected boolean |
isDefinedOutput(String outputName) |
protected boolean |
isDefinedResource(String resourceName) |
protected boolean |
isPromptPending() |
void |
outputMissingError(String paramName) |
void |
promptNeeded() |
void |
promptNow() |
void |
resourceComponentSettingError(String paramName) |
void |
resourceMissingError(String paramName) |
protected void |
saveSetting(String name,
Object value) |
void |
setActionDefinition(org.pentaho.actionsequence.dom.IActionDefinition actionDefinition) |
void |
setActionName(String actionName) |
void |
setComponentDefinition(org.dom4j.Node componentDefinition) |
void |
setComponentDefinitionMap(Map<String,String> componentDefinitionMap) |
protected void |
setFeedbackMimeType(String mimeType) |
void |
setInstanceId(String instanceId) |
void |
setLoggingLevel(int logLevel) |
void |
setLogId(String lId) |
void |
setMessages(List messages) |
protected void |
setOutputMimeType(String mimeType) |
protected void |
setOutputValue(String outputName,
Object value) |
void |
setProcessId(String processId) |
void |
setRuntimeContext(IRuntimeContext runtimeContext) |
void |
setSession(IPentahoSession session) |
void |
trace(String message) |
void |
trace(String message,
Throwable error) |
int |
validate() |
boolean |
validateAction() |
protected boolean |
validateSystemSettings() |
void |
warn(String message) |
void |
warn(String message,
Throwable error) |
protected int loggingLevel
public static final String LOGID_MASK1
public static final String LOGID_MASK2
public static final String LOGID_SEPARATOR
public String EMPTYLOGID
protected static final boolean debug
public boolean validateAction()
protected boolean validateSystemSettings()
public void done()
done
in interface IComponent
public boolean init()
init
in interface IComponent
public void setLogId(String lId)
public org.apache.commons.logging.Log getLogger()
public void genLogIdFromSession(IPentahoSession sess)
public void genLogIdFromInfo(String sessId, String procId, String actName, String instId)
public String getObjectName()
getObjectName
in interface IAuditable
public int getLoggingLevel()
getLoggingLevel
in interface ILogger
public void setLoggingLevel(int logLevel)
setLoggingLevel
in interface ILogger
public List getMessages()
getMessages
in interface IComponent
public void setMessages(List messages)
setMessages
in interface IComponent
public void setInstanceId(String instanceId)
setInstanceId
in interface IComponent
public String getInstanceId()
getInstanceId
in interface IComponent
public void setActionName(String actionName)
setActionName
in interface IComponent
public String getActionName()
getActionName
in interface IAuditable
getActionName
in interface IComponent
public void setProcessId(String processId)
setProcessId
in interface IComponent
public String getProcessId()
getProcessId
in interface IAuditable
getProcessId
in interface IComponent
public void setComponentDefinitionMap(Map<String,String> componentDefinitionMap)
setComponentDefinitionMap
in interface IComponent
public void setComponentDefinition(org.dom4j.Node componentDefinition)
setComponentDefinition
in interface IComponent
public org.dom4j.Node getComponentDefinition()
getComponentDefinition
in interface IComponent
public void setRuntimeContext(IRuntimeContext runtimeContext)
setRuntimeContext
in interface IComponent
public IRuntimeContext getRuntimeContext()
getRuntimeContext
in interface IComponent
public void setSession(IPentahoSession session)
setSession
in interface IComponent
public IPentahoSession getSession()
getSession
in interface IComponent
public String getLogId()
protected boolean isDefinedInput(String inputName)
protected boolean isDefinedOutput(String outputName)
protected boolean isDefinedResource(String resourceName)
public final int validate()
validate
in interface IComponent
public boolean getInitOk()
protected Set getOutputNames()
protected Set getInputNames()
protected Set getResourceNames()
protected boolean feedbackAllowed()
protected IActionSequenceResource getResource(String resourceName)
protected InputStream getResourceInputStream(IActionSequenceResource resource) throws FileNotFoundException
FileNotFoundException
protected InputStream getInputStream(String inputName)
protected int getOutputPreference()
protected IContentItem getOutputItem(String outputName, String mimeType, String extension)
protected boolean getInputBooleanValue(String inputName, boolean defaultValue)
protected long getInputLongValue(String inputName, long defaultValue)
public void promptNeeded()
public void promptNow()
public String getResourceAsString(IActionSequenceResource resource)
public String getInitFailMessage()
public String createNewInstance(boolean persisted, Map parameters, boolean forceImmediateWrite)
public void inputMissingError(String paramName)
public void outputMissingError(String paramName)
public void resourceMissingError(String paramName)
public void resourceComponentSettingError(String paramName)
public int execute()
execute
in interface IComponent
public String getId()
getId
in interface IAuditable
public String getActionTitle()
protected IContentItem getOutputContentItem(String mimeType)
protected IContentItem getOutputContentItem(String outputName, String mimeType)
protected OutputStream getDefaultOutputStream(String mimeType)
protected IActionParameter getOutputItem(String outputName)
protected String getSolutionName()
protected String getSolutionPath()
protected IActionParameter getInputParameter(String parameterName)
protected boolean isPromptPending()
protected void setFeedbackMimeType(String mimeType)
protected void setOutputMimeType(String mimeType)
protected OutputStream getFeedbackOutputStream()
protected void createFeedbackParameter(IActionParameter actionParam)
protected void createFeedbackParameter(ISelectionMapper selMap, String fieldName, Object defaultValues)
protected void createFeedbackParameter(String fieldName, String displayName, String hint, String defaultValue, boolean visible)
public void createFeedbackParameter(String fieldName, String displayName, String hint, Object defaultValues, List values, Map dispNames, String displayStyle)
protected org.pentaho.commons.connection.IPentahoStreamSource getResourceDataSource(IActionSequenceResource resource) throws FileNotFoundException
FileNotFoundException
public void setActionDefinition(org.pentaho.actionsequence.dom.IActionDefinition actionDefinition)
setActionDefinition
in interface IComponent
public org.pentaho.actionsequence.dom.IActionDefinition getActionDefinition()
getActionDefinition
in interface IComponent
Copyright © 2017 Hitachi Vantara. All rights reserved.