|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.pentaho.di.trans.Trans
public class Trans
This class represents the information and operations associated with the concept of a Transformation. It loads, instantiates, initializes, runs, and monitors the execution of the transformation contained in the specified TransInfo object.
| Field Summary | |
|---|---|
int |
class_nr
The class number. |
static String |
CONFIGURATION_IN_EXPORT_FILENAME
Constant specifying a filename containing XML to inject into a ZIP file created during resource export. |
static String |
REPLAY_DATE_FORMAT
The replay date format. |
static String |
STRING_FINISHED
Constant indicating a transformation status of Finished. |
static String |
STRING_HALTING
Constant indicating a transformation status of Halting. |
static String |
STRING_INITIALIZING
Constant indicating a transformation status of Initializing. |
static String |
STRING_PAUSED
Constant indicating a transformation status of Paused. |
static String |
STRING_PREPARING
Constant indicating a transformation status of Preparing for execution. |
static String |
STRING_RUNNING
TConstant indicating a transformation status of Running. |
static String |
STRING_STOPPED
Constant indicating a transformation status of Stopped. |
static String |
STRING_WAITING
Constant indicating a transformation status of Waiting. |
static int |
TYPE_DISP_1_1
Constant indicating a dispatch type of 1-to-1. |
static int |
TYPE_DISP_1_N
Constant indicating a dispatch type of 1-to-N. |
static int |
TYPE_DISP_N_1
Constant indicating a dispatch type of N-to-1. |
static int |
TYPE_DISP_N_M
Constant indicating a dispatch type of N-to-N. |
static int |
TYPE_DISP_N_N
Constant indicating a dispatch type of N-to-N. |
| Constructor Summary | |
|---|---|
Trans()
Instantiates a new transformation. |
|
Trans(TransMeta transMeta)
Initializes a transformation from transformation meta-data defined in memory. |
|
Trans(TransMeta transMeta,
LoggingObjectInterface parent)
Initializes a transformation from transformation meta-data defined in memory. |
|
Trans(VariableSpace parentVariableSpace,
Repository rep,
String name,
String dirname,
String filename)
Instantiates a new transformation using any of the provided parameters including the variable bindings, a repository, a name, a repository directory name, and a filename. |
|
| Method Summary | |
|---|---|
void |
activateParameters()
Activates all parameters by setting their values. |
void |
addParameterDefinition(String key,
String defValue,
String description)
Adds a parameter definition to this transformation. |
RowProducer |
addRowProducer(String stepname,
int copynr)
This adds a row producer to the transformation that just got set up. |
void |
addTransListener(TransListener transListener)
Adds a transformation listener. |
void |
addTransStoppedListener(TransStoppedListener transStoppedListener)
Adds a stop-event listener to the transformation. |
void |
beginProcessing()
Begin processing. |
void |
calculateBatchIdAndDateRange()
Calculate the batch id and date range for the transformation. |
void |
cleanup()
This method performs any cleanup operations, typically called after the transformation has finished. |
static int |
cleanupCluster(LogChannelInterface log,
TransSplitter transSplitter)
Cleanup the cluster, including the master and all slaves, and return the number of errors that occurred. |
static void |
cleanupSlaveServer(TransSplitter transSplitter,
SlaveServer slaveServer,
TransMeta slaveTransMeta)
Cleanup the slave server as part of a clustered transformation. |
void |
clearParameters()
Clear the values of all parameters. |
void |
copyParametersFrom(NamedParams params)
Copy parameters from a NamedParams object. |
void |
copyVariablesFrom(VariableSpace space)
Copies variables from a given variable space to this transformation. |
String |
environmentSubstitute(String aString)
Substitutes any variable values into the given string, and returns the resolved string. |
String[] |
environmentSubstitute(String[] aString)
Substitutes any variable values into each of the given strings, and returns an array containing the resolved string(s). |
void |
eraseParameters()
Remove all parameters. |
void |
execute(String[] arguments)
Executes the transformation. |
static TransSplitter |
executeClustered(TransMeta transMeta,
TransExecutionConfiguration executionConfiguration)
Execute the transformation in a clustered fashion. |
static void |
executeClustered(TransSplitter transSplitter,
TransExecutionConfiguration executionConfiguration)
Executes an existing TransSplitter, with the transformation already split. |
List<StepInterface> |
findBaseSteps(String stepname)
Find the base steps for the step with the specified name. |
StepDataInterface |
findDataInterface(String name)
Find the data interface for the step with the specified name. |
MappingInput[] |
findMappingInput()
Gets the mapping inputs for each step in the transformation. |
MappingOutput[] |
findMappingOutput()
Gets the mapping outputs for each step in the transformation. |
RowSet |
findRowSet(String rowsetname)
Finds the RowSet with the specified name. |
RowSet |
findRowSet(String from,
int fromcopy,
String to,
int tocopy)
Finds the RowSet between two steps (or copies of steps). |
StepInterface |
findRunThread(String stepname)
Find the run thread for the step with the specified name. |
Map<String,Trans> |
getActiveSubtransformations()
Gets the active sub-transformations. |
long |
getBatchId()
Gets the batch ID of the transformation. |
boolean |
getBooleanValueOfVariable(String variableName,
boolean defaultValue)
Returns a boolean representation of the specified variable after performing any necessary substitution. |
static Result |
getClusteredTransformationResult(LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob)
Gets the clustered transformation result. |
String |
getContainerObjectId()
Gets the container object ID. |
Date |
getCurrentDate()
Gets the current date/time object. |
Date |
getDepDate()
Gets the dependency date for the transformation. |
Date |
getEndDate()
Gets the end date/time object for the transformation. |
int |
getEnded()
Gets the number of steps in the transformation that are in an end state, such as Finished, Halted, or Stopped. |
int |
getErrors()
Gets the number of errors that have occurred during execution of the transformation. |
String |
getFilename()
Gets the filename of the transformation, or null if no filename exists |
Date |
getJobEndDate()
Gets the job end date. |
Date |
getJobStartDate()
Gets the job start date. |
long |
getLastProcessed()
Gets a representable metric of the "processed" lines of the last step. |
LogChannelInterface |
getLogChannel()
Gets the log channel interface for the transformation. |
String |
getLogChannelId()
Gets the log channel ID. |
Date |
getLogDate()
Gets the date the transformation was logged. |
List<LoggingHierarchy> |
getLoggingHierarchy()
Gets the logging hierarchy. |
LogLevel |
getLogLevel()
Gets the log level. |
String |
getMappingStepName()
Gets the mapping step name. |
String |
getName()
Gets the name of the transformation. |
String |
getObjectCopy()
Gets the object copy. |
ObjectId |
getObjectId()
Gets the object ID. |
String |
getObjectName()
Gets the object name. |
ObjectRevision |
getObjectRevision()
Gets the object revision. |
LoggingObjectType |
getObjectType()
Gets the object type. |
String |
getParameterDefault(String key)
Gets the default value of the specified parameter. |
String |
getParameterDescription(String key)
Gets the description of the specified parameter. |
String |
getParameterValue(String key)
Gets the value of the specified parameter. |
LoggingObjectInterface |
getParent()
Gets the parent logging object interface. |
Job |
getParentJob()
Gets the parent job, or null if there is no parent. |
Trans |
getParentTrans()
Gets the parent transformation, which is null if no parent transformation exists. |
VariableSpace |
getParentVariableSpace()
Gets the parent variable space. |
long |
getPassedBatchId()
Get the batch ID that is passed from the parent job to the transformation. |
Date |
getRegistrationDate()
Gets the registration date. |
Date |
getReplayDate()
Gets the replay date. |
Repository |
getRepository()
Gets the repository object for the transformation. |
RepositoryDirectoryInterface |
getRepositoryDirectory()
Gets the repository directory. |
Result |
getResult()
Gets the result of the transformation. |
List<RowSet> |
getRowsets()
Gets the rowsets for the transformation. |
StepInterface |
getRunThread(int i)
Gets the run thread for the step at the specified index. |
StepInterface |
getRunThread(String name,
int copy)
Gets the run thread for the step with the specified name and copy number. |
PrintWriter |
getServletPrintWriter()
Gets the servlet print writer. |
SocketRepository |
getSocketRepository()
Gets the socket repository. |
Date |
getStartDate()
Gets the start date/time object for the transformation. |
String |
getStatus()
Gets the status of the transformation (Halting, Finished, Paused, etc.) |
StepDataInterface |
getStepDataInterface(String stepname,
int stepcopy)
Finds the StepDataInterface (currently) associated with the specified step. |
StepInterface |
getStepInterface(String stepname,
int copy)
Find the StepInterface (thread) by looking it up using the name. |
Map<String,List<StepPerformanceSnapShot>> |
getStepPerformanceSnapShots()
Gets a named list (map) of step performance snapshots. |
List<StepMetaDataCombi> |
getSteps()
Gets a list of steps in the transformation. |
String |
getThreadName()
Gets the name of the thread that contains the transformation. |
List<TransListener> |
getTransListeners()
Gets a list of the transformation listeners. |
TransMeta |
getTransMeta()
Gets the meta-data for the transformation. |
BaseStepData.StepExecutionStatus[] |
getTransStepExecutionStatusLookup()
Checks the execution status of each step in the transformations. |
boolean[] |
getTransStepIsRunningLookup()
Checks whether the transformation steps are running lookup. |
List<TransStoppedListener> |
getTransStoppedListeners()
Gets the list of stop-event listeners for the transformation. |
String |
getVariable(String variableName)
Gets the value of the specified variable, or returns a default value if no such variable exists. |
String |
getVariable(String variableName,
String defaultValue)
Gets the value of the specified variable, or returns a default value if no such variable exists. |
boolean |
hasHaltedSteps()
Checks whether the transformation has any steps that are halted. |
boolean |
hasStepStarted(String sname,
int copy)
Checks whether the specified step (or step copy) has started. |
void |
initializeVariablesFrom(VariableSpace parent)
Sets the values of the transformation's variables to the values from the parent variables. |
void |
injectVariables(Map<String,String> prop)
Injects variables using the given Map. |
boolean |
isFinished()
Checks if the transformation is finished\. |
boolean |
isInitializing()
Checks whether the transformation is initializing. |
boolean |
isMonitored()
Checks whether the running transformation is being monitored. |
boolean |
isPaused()
Checks if the transformation is paused. |
boolean |
isPreparing()
Checks whether the transformation is preparing for execution. |
boolean |
isPreview()
Checks whether the transformation is being previewed. |
boolean |
isReadyToStart()
Checks whether the transformation is ready to start (i.e. |
boolean |
isRunning()
Checks whether the transformation is running. |
boolean |
isSafeModeEnabled()
Checks whether safe mode is enabled. |
boolean |
isStopped()
Checks if the transformation is stopped. |
void |
killAll()
Attempts to stops all running steps and subtransformations. |
String[] |
listParameters()
Gets a list of the parameters for the transformation. |
String[] |
listVariables()
Gets a list of variable names for the transformation. |
void |
logSummary(StepInterface si)
Logs a summary message for the specified step. |
static long |
monitorClusteredTransformation(LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob)
Monitors a clustered transformation every second, after all the transformations in a cluster schema are running. Now we should verify that they are all running as they should. If a transformation has an error, we should kill them all. This should happen in a separate thread to prevent blocking of the UI. When the master and slave transformations have all finished, we should also run a cleanup on those transformations to release sockets, etc. |
static long |
monitorClusteredTransformation(LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob,
int sleepTimeSeconds)
Monitors a clustered transformation every second, after all the transformations in a cluster schema are running. Now we should verify that they are all running as they should. If a transformation has an error, we should kill them all. This should happen in a separate thread to prevent blocking of the UI. When the master and slave transformations have all finished, we should also run a cleanup on those transformations to release sockets, etc. |
static void |
monitorRemoteTransformation(LogChannelInterface log,
String carteObjectId,
String transName,
SlaveServer remoteSlaveServer)
Monitors a remote transformation every 5 seconds. |
static void |
monitorRemoteTransformation(LogChannelInterface log,
String carteObjectId,
String transName,
SlaveServer remoteSlaveServer,
int sleepTimeSeconds)
Monitors a remote transformation at the specified interval. |
int |
nrActiveSteps()
Gets the number of active (i.e. |
int |
nrSteps()
Gets the number of steps in this transformation. |
void |
pauseRunning()
Pauses the transformation (pause all steps). |
void |
prepareExecution(String[] arguments)
Prepares the transformation for execution. |
void |
printStats(int seconds)
Logs the execution statistics for the transformation for the specified time interval. |
void |
resumeRunning()
Resumes running the transformation after a pause (resume all steps). |
static String |
sendToSlaveServer(TransMeta transMeta,
TransExecutionConfiguration executionConfiguration,
Repository repository)
Send the transformation for execution to a Carte slave server. |
void |
setBatchId(long batchId)
Sets the batch ID of the transformation. |
void |
setContainerObjectId(String containerObjectId)
Sets the container object ID. |
void |
setInitializing(boolean initializing)
Sets whether the transformation is initializing. |
void |
setInternalKettleVariables(VariableSpace var)
Sets the internal kettle variables. |
void |
setJobEndDate(Date jobEndDate)
Sets the job end date. |
void |
setJobStartDate(Date jobStartDate)
Sets the job start date. |
void |
setLog(LogChannelInterface log)
Sets the log channel interface for the transformation. |
void |
setLogLevel(LogLevel logLevel)
Sets the log level. |
void |
setMappingStepName(String mappingStepName)
Sets the mapping step name. |
void |
setMonitored(boolean monitored)
Sets whether the running transformation should be monitored. |
void |
setParameterValue(String key,
String value)
Sets the value for the specified parameter. |
void |
setParent(LoggingObjectInterface parent)
Sets the parent logging object. |
void |
setParentJob(Job parentJob)
Sets the parent job for the transformation. |
void |
setParentTrans(Trans parentTrans)
Sets the parent transformation. |
void |
setParentVariableSpace(VariableSpace parent)
Sets the parent variable space. |
void |
setPassedBatchId(long jobBatchId)
Sets the passed batch ID of the transformation from the batch ID of the parent job. |
void |
setPreparing(boolean preparing)
Sets whether the transformation is preparing for execution. |
void |
setPreview(boolean preview)
Sets whether the transformation is being previewed. |
void |
setReplayDate(Date replayDate)
Sets the replay date. |
void |
setRepository(Repository repository)
Sets the repository object for the transformation. |
void |
setRunning(boolean running)
Sets whether the transformation is running. |
void |
setSafeModeEnabled(boolean safeModeEnabled)
Turn on safe mode during running: the transformation will run slower but with more checking enabled. |
void |
setServletPrintWriter(PrintWriter servletPrintWriter)
Sets the servlet print writer. |
void |
setSocketRepository(SocketRepository socketRepository)
Sets the socket repository. |
void |
setStepPerformanceSnapShots(Map<String,List<StepPerformanceSnapShot>> stepPerformanceSnapShots)
Sets the named list (map) of step performance snapshots. |
void |
setThreadName(String threadName)
Sets the thread name for the transformation. |
void |
setTransListeners(List<TransListener> transListeners)
Sets the list of transformation listeners. |
void |
setTransMeta(TransMeta transMeta)
Sets the meta-data for the transformation. |
void |
setTransStoppedListeners(List<TransStoppedListener> transStoppedListeners)
Sets the list of stop-event listeners for the transformation. |
void |
setVariable(String variableName,
String variableValue)
Sets the value of the specified variable to the specified value. |
void |
shareVariablesWith(VariableSpace space)
Shares a variable space from another variable space. |
void |
startThreads()
Starts the threads prepared by prepareThreads(). |
void |
stopAll()
Stops all steps from running, and alerts any registered listeners. |
String |
toString()
Gets a string representation of the transformation. |
void |
waitUntilFinished()
Waits until all RunThreads have finished. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final String REPLAY_DATE_FORMAT
public int class_nr
public static final int TYPE_DISP_1_1
public static final int TYPE_DISP_1_N
public static final int TYPE_DISP_N_1
public static final int TYPE_DISP_N_N
public static final int TYPE_DISP_N_M
public static final String STRING_FINISHED
public static final String STRING_RUNNING
public static final String STRING_PAUSED
public static final String STRING_PREPARING
public static final String STRING_INITIALIZING
public static final String STRING_WAITING
public static final String STRING_STOPPED
public static final String STRING_HALTING
public static final String CONFIGURATION_IN_EXPORT_FILENAME
| Constructor Detail |
|---|
public Trans()
public Trans(TransMeta transMeta)
transMeta - the transformation meta-data to use.
public Trans(TransMeta transMeta,
LoggingObjectInterface parent)
transMeta - the transformation meta-data to use.parent - the parent job that is executing this transformation
public Trans(VariableSpace parentVariableSpace,
Repository rep,
String name,
String dirname,
String filename)
throws KettleException
parentVariableSpace - the parent variable spacerep - the repositoryname - the name of the transformationdirname - the dirname the repository directory namefilename - the filename containing the transformation definition
KettleException - if any error occurs during loading, parsing, or creation of the transformation| Method Detail |
|---|
public void setParent(LoggingObjectInterface parent)
parent - the new parentpublic LogChannelInterface getLogChannel()
getLogChannel in interface HasLogChannelInterfaceHasLogChannelInterface.getLogChannel()public void setLog(LogChannelInterface log)
log - the new log channel interfacepublic String getName()
public void execute(String[] arguments)
throws KettleException
arguments - the arguments
KettleException - if the transformation could not be prepared (initialized)
public void prepareExecution(String[] arguments)
throws KettleException
arguments - the arguments to use for this transformation
KettleException - in case the transformation could not be prepared (initialized)
public void startThreads()
throws KettleException
KettleException - if there is a communication error with a remote output socket.public void cleanup()
public void logSummary(StepInterface si)
si - the step interfacepublic void waitUntilFinished()
public int getErrors()
public int getEnded()
public boolean isFinished()
public void killAll()
public void printStats(int seconds)
seconds - the time interval (in seconds)public long getLastProcessed()
public RowSet findRowSet(String rowsetname)
rowsetname - the rowsetname
public RowSet findRowSet(String from,
int fromcopy,
String to,
int tocopy)
from - the name of the "from" stepfromcopy - the copy number of the "from" stepto - the name of the "to" steptocopy - the copy number of the "to" step
public boolean hasStepStarted(String sname,
int copy)
sname - the step namecopy - the copy number
public void stopAll()
public int nrSteps()
public int nrActiveSteps()
public boolean[] getTransStepIsRunningLookup()
public BaseStepData.StepExecutionStatus[] getTransStepExecutionStatusLookup()
public StepInterface getRunThread(int i)
i - the index of the desired step
public StepInterface getRunThread(String name,
int copy)
name - the step namecopy - the copy number
public void calculateBatchIdAndDateRange()
throws KettleTransException
KettleTransException - if there are any errors during calculation
public void beginProcessing()
throws KettleTransException
KettleTransException - the kettle trans exceptionpublic Result getResult()
public StepInterface findRunThread(String stepname)
stepname - the step name
public List<StepInterface> findBaseSteps(String stepname)
stepname - the step name
public StepDataInterface findDataInterface(String name)
name - the step name
public Date getStartDate()
public Date getEndDate()
public boolean isMonitored()
public void setMonitored(boolean monitored)
monitored - true if the running transformation should be monitored, false otherwisepublic TransMeta getTransMeta()
public void setTransMeta(TransMeta transMeta)
transMeta - The transformation meta-data to set.public Date getCurrentDate()
public Date getDepDate()
public Date getLogDate()
public List<RowSet> getRowsets()
public List<StepMetaDataCombi> getSteps()
public String toString()
toString in class ObjectObject.toString()public MappingInput[] findMappingInput()
public MappingOutput[] findMappingOutput()
public StepInterface getStepInterface(String stepname,
int copy)
stepname - The name of the step to look forcopy - the copy number of the step to look for
public Date getReplayDate()
public void setReplayDate(Date replayDate)
replayDate - the new replay datepublic void setSafeModeEnabled(boolean safeModeEnabled)
safeModeEnabled - true for safe modepublic boolean isSafeModeEnabled()
public RowProducer addRowProducer(String stepname,
int copynr)
throws KettleException
stepname - The step to produce rows forcopynr - The copynr of the step to produce row for (normally 0 unless you have multiple copies running)
KettleException - in case the thread/step to produce rows for could not be found.execute(String[]),
prepareExecution(String[])public Job getParentJob()
public void setParentJob(Job parentJob)
parentJob - The parent job to set
public StepDataInterface getStepDataInterface(String stepname,
int stepcopy)
stepname - The name of the step to look forstepcopy - The copy number (0 based) of the step
public boolean hasHaltedSteps()
public Date getJobStartDate()
public Date getJobEndDate()
public void setJobEndDate(Date jobEndDate)
jobEndDate - the jobEndDate to setpublic void setJobStartDate(Date jobStartDate)
jobStartDate - the jobStartDate to setpublic long getPassedBatchId()
public void setPassedBatchId(long jobBatchId)
jobBatchId - the jobBatchId to setpublic long getBatchId()
public void setBatchId(long batchId)
batchId - the batch ID to setpublic String getThreadName()
public void setThreadName(String threadName)
threadName - the thread namepublic String getStatus()
public boolean isInitializing()
public void setInitializing(boolean initializing)
initializing - true if the transformation is initializing, false otherwisepublic boolean isPreparing()
public void setPreparing(boolean preparing)
preparing - true if the transformation is preparing for execution, false otherwisepublic boolean isRunning()
public void setRunning(boolean running)
running - true if the transformation is running, false otherwise
public static final TransSplitter executeClustered(TransMeta transMeta,
TransExecutionConfiguration executionConfiguration)
throws KettleException
transMeta - the transformation's meta-dataexecutionConfiguration - the execution configuration
KettleException - the kettle exception
public static final void executeClustered(TransSplitter transSplitter,
TransExecutionConfiguration executionConfiguration)
throws KettleException
transSplitter - the trans splitterexecutionConfiguration - the execution configuration
KettleException - the kettle exceptionSpoonTransformationDelegate
public static final long monitorClusteredTransformation(LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob)
log - the log interface channeltransSplitter - the transformation splitter objectparentJob - the parent job when executed in a job, otherwise just set to null
public static final long monitorClusteredTransformation(LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob,
int sleepTimeSeconds)
log - the subject to use for loggingtransSplitter - the transformation splitter objectparentJob - the parent job when executed in a job, otherwise just set to nullsleepTimeSeconds - the sleep time in seconds in between slave transformation status polling
public static int cleanupCluster(LogChannelInterface log,
TransSplitter transSplitter)
log - the log channel interfacetransSplitter - the TransSplitter object
public static void cleanupSlaveServer(TransSplitter transSplitter,
SlaveServer slaveServer,
TransMeta slaveTransMeta)
throws KettleException
transSplitter - the TransSplitter objectslaveServer - the slave serverslaveTransMeta - the slave transformation meta-data
KettleException - if any errors occur during cleanup
public static final Result getClusteredTransformationResult(LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob)
log - the log channel interfacetransSplitter - the TransSplitter objectparentJob - the parent job
public static String sendToSlaveServer(TransMeta transMeta,
TransExecutionConfiguration executionConfiguration,
Repository repository)
throws KettleException
transMeta - the transformation meta-dataexecutionConfiguration - the transformation execution configurationrepository - the repository
KettleException - if any errors occur during the dispatch to the slave serverpublic boolean isReadyToStart()
prepareExecution(String[])public void setInternalKettleVariables(VariableSpace var)
var - the new internal kettle variablespublic void copyVariablesFrom(VariableSpace space)
copyVariablesFrom in interface VariableSpacespace - the variable spaceVariableSpace.copyVariablesFrom(org.pentaho.di.core.variables.VariableSpace)public String environmentSubstitute(String aString)
environmentSubstitute in interface VariableSpaceaString - the string to resolve against environment variables
VariableSpace.environmentSubstitute(java.lang.String)public String[] environmentSubstitute(String[] aString)
environmentSubstitute in interface VariableSpaceaString - an array of strings to resolve against environment variables
VariableSpace.environmentSubstitute(java.lang.String[])public VariableSpace getParentVariableSpace()
getParentVariableSpace in interface VariableSpaceVariableSpace.getParentVariableSpace()public void setParentVariableSpace(VariableSpace parent)
setParentVariableSpace in interface VariableSpaceparent - the new parent variable spaceVariableSpace.setParentVariableSpace(org.pentaho.di.core.variables.VariableSpace)
public String getVariable(String variableName,
String defaultValue)
getVariable in interface VariableSpacevariableName - the variable namedefaultValue - the default value
VariableSpace.getVariable(java.lang.String, java.lang.String)public String getVariable(String variableName)
getVariable in interface VariableSpacevariableName - the variable name
VariableSpace.getVariable(java.lang.String)
public boolean getBooleanValueOfVariable(String variableName,
boolean defaultValue)
getBooleanValueOfVariable in interface VariableSpacevariableName - the variable namedefaultValue - the default value
VariableSpace.getBooleanValueOfVariable(java.lang.String, boolean)public void initializeVariablesFrom(VariableSpace parent)
initializeVariablesFrom in interface VariableSpaceparent - the parentVariableSpace.initializeVariablesFrom(org.pentaho.di.core.variables.VariableSpace)public String[] listVariables()
listVariables in interface VariableSpaceVariableSpace.listVariables()
public void setVariable(String variableName,
String variableValue)
setVariable in interface VariableSpacevariableName - the variable namevariableValue - the variable valueVariableSpace.setVariable(java.lang.String, java.lang.String)public void shareVariablesWith(VariableSpace space)
shareVariablesWith in interface VariableSpacespace - the variable spaceVariableSpace.shareVariablesWith(org.pentaho.di.core.variables.VariableSpace)public void injectVariables(Map<String,String> prop)
injectVariables in interface VariableSpaceprop - the property mapVariableSpace.injectVariables(java.util.Map)public void pauseRunning()
public void resumeRunning()
public boolean isPreview()
public void setPreview(boolean preview)
preview - true if the transformation is being previewed, false otherwisepublic Repository getRepository()
public void setRepository(Repository repository)
repository - the repository object to setpublic Map<String,List<StepPerformanceSnapShot>> getStepPerformanceSnapShots()
public void setStepPerformanceSnapShots(Map<String,List<StepPerformanceSnapShot>> stepPerformanceSnapShots)
stepPerformanceSnapShots - a named list (map) of step performance snapshots to setpublic List<TransListener> getTransListeners()
public void setTransListeners(List<TransListener> transListeners)
transListeners - the transListeners to setpublic void addTransListener(TransListener transListener)
transListener - the trans listenerpublic void setTransStoppedListeners(List<TransStoppedListener> transStoppedListeners)
transStoppedListeners - the list of stop-event listeners to setpublic List<TransStoppedListener> getTransStoppedListeners()
public void addTransStoppedListener(TransStoppedListener transStoppedListener)
transStoppedListener - the stop-event listener to addpublic boolean isPaused()
public boolean isStopped()
public static void monitorRemoteTransformation(LogChannelInterface log,
String carteObjectId,
String transName,
SlaveServer remoteSlaveServer)
log - the log channel interfacecarteObjectId - the Carte object IDtransName - the transformation nameremoteSlaveServer - the remote slave server
public static void monitorRemoteTransformation(LogChannelInterface log,
String carteObjectId,
String transName,
SlaveServer remoteSlaveServer,
int sleepTimeSeconds)
log - the log channel interfacecarteObjectId - the Carte object IDtransName - the transformation nameremoteSlaveServer - the remote slave serversleepTimeSeconds - the sleep time (in seconds)
public void addParameterDefinition(String key,
String defValue,
String description)
throws DuplicateParamException
addParameterDefinition in interface NamedParamskey - the name of the parameterdefValue - the default value for the parameterdescription - the description of the parameter
DuplicateParamException - the duplicate param exceptionNamedParams.addParameterDefinition(java.lang.String, java.lang.String, java.lang.String)
public String getParameterDefault(String key)
throws UnknownParamException
getParameterDefault in interface NamedParamskey - the name of the parameter
UnknownParamException - if the parameter does not existNamedParams.getParameterDefault(java.lang.String)
public String getParameterDescription(String key)
throws UnknownParamException
getParameterDescription in interface NamedParamskey - the name of the parameter
UnknownParamException - if the parameter does not existNamedParams.getParameterDescription(java.lang.String)
public String getParameterValue(String key)
throws UnknownParamException
getParameterValue in interface NamedParamskey - the name of the parameter
UnknownParamException - if the parameter does not existNamedParams.getParameterValue(java.lang.String)public String[] listParameters()
listParameters in interface NamedParamsNamedParams.listParameters()
public void setParameterValue(String key,
String value)
throws UnknownParamException
setParameterValue in interface NamedParamskey - the name of the parametervalue - the name of the value
UnknownParamException - if the parameter does not existNamedParams.setParameterValue(java.lang.String, java.lang.String)public void eraseParameters()
eraseParameters in interface NamedParamsNamedParams.eraseParameters()public void clearParameters()
clearParameters in interface NamedParamsNamedParams.clearParameters()public void activateParameters()
activateParameters in interface NamedParamsNamedParams.activateParameters()public void copyParametersFrom(NamedParams params)
copyParametersFrom in interface NamedParamsparams - the NamedParams object from which to copy the parametersNamedParams.copyParametersFrom(org.pentaho.di.core.parameters.NamedParams)public Trans getParentTrans()
public void setParentTrans(Trans parentTrans)
parentTrans - the parent Trans to setpublic String getMappingStepName()
public void setMappingStepName(String mappingStepName)
mappingStepName - the name of the mapping step that created this transformationpublic void setSocketRepository(SocketRepository socketRepository)
socketRepository - the new socket repositorypublic SocketRepository getSocketRepository()
public String getObjectName()
getObjectName in interface LoggingObjectInterfaceLoggingObjectInterface.getObjectName()public String getObjectCopy()
getObjectCopy in interface LoggingObjectInterfaceLoggingObjectInterface.getObjectCopy()public String getFilename()
getFilename in interface LoggingObjectInterfaceLoggingObjectInterface.getFilename()public String getLogChannelId()
getLogChannelId in interface LoggingObjectInterfaceLoggingObjectInterface.getLogChannelId()public ObjectId getObjectId()
getObjectId in interface LoggingObjectInterfaceLoggingObjectInterface.getObjectId()public ObjectRevision getObjectRevision()
getObjectRevision in interface LoggingObjectInterfaceLoggingObjectInterface.getObjectRevision()public LoggingObjectType getObjectType()
getObjectType in interface LoggingObjectInterfaceLoggingObjectInterface.getObjectType()public LoggingObjectInterface getParent()
getParent in interface LoggingObjectInterfaceLoggingObjectInterface.getParent()public RepositoryDirectoryInterface getRepositoryDirectory()
getRepositoryDirectory in interface LoggingObjectInterfaceLoggingObjectInterface.getRepositoryDirectory()public LogLevel getLogLevel()
getLogLevel in interface LoggingObjectInterfaceLoggingObjectInterface.getLogLevel()public void setLogLevel(LogLevel logLevel)
logLevel - the new log levelpublic List<LoggingHierarchy> getLoggingHierarchy()
public Map<String,Trans> getActiveSubtransformations()
public String getContainerObjectId()
getContainerObjectId in interface LoggingObjectInterfacepublic void setContainerObjectId(String containerObjectId)
containerObjectId - the Carte object ID to setpublic Date getRegistrationDate()
getRegistrationDate in interface LoggingObjectInterfacepublic void setServletPrintWriter(PrintWriter servletPrintWriter)
servletPrintWriter - the new servlet print writerpublic PrintWriter getServletPrintWriter()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||