Search in sources :

Example 1 with TransformationType

use of org.pentaho.di.trans.TransMeta.TransformationType in project pentaho-kettle by pentaho.

the class SingleThreadedTransExecutor method init.

public boolean init() throws KettleException {
    // 
    for (StepMetaDataCombi combi : steps) {
        TransformationType[] types = combi.stepMeta.getStepMetaInterface().getSupportedTransformationTypes();
        boolean ok = false;
        for (TransformationType type : types) {
            if (type == TransformationType.SingleThreaded) {
                ok = true;
            }
        }
        if (!ok) {
            throw new KettleException("Step '" + combi.stepname + "' of type '" + combi.stepMeta.getStepID() + "' is not yet supported in a Single Threaded transformation engine.");
        }
    }
    // 
    for (StepMetaDataCombi combi : steps) {
        boolean ok = combi.step.init(combi.meta, combi.data);
        if (!ok) {
            return false;
        }
    }
    return true;
}
Also used : KettleException(org.pentaho.di.core.exception.KettleException) StepMetaDataCombi(org.pentaho.di.trans.step.StepMetaDataCombi) TransformationType(org.pentaho.di.trans.TransMeta.TransformationType)

Aggregations

KettleException (org.pentaho.di.core.exception.KettleException)1 TransformationType (org.pentaho.di.trans.TransMeta.TransformationType)1 StepMetaDataCombi (org.pentaho.di.trans.step.StepMetaDataCombi)1