use of org.pentaho.di.trans.step.errorhandling.Stream in project pentaho-kettle by pentaho.
the class SwitchCaseMeta method getStepIOMeta.
/**
* Returns the Input/Output metadata for this step.
*/
public StepIOMetaInterface getStepIOMeta() {
if (ioMeta == null) {
ioMeta = new StepIOMeta(true, false, false, false, false, true);
//
for (SwitchCaseTarget target : caseTargets) {
StreamInterface stream = new Stream(StreamType.TARGET, target.caseTargetStep, BaseMessages.getString(PKG, "SwitchCaseMeta.TargetStream.CaseTarget.Description", Const.NVL(target.caseValue, "")), StreamIcon.TARGET, target);
ioMeta.addStream(stream);
}
//
if (getDefaultTargetStep() != null) {
ioMeta.addStream(new Stream(StreamType.TARGET, getDefaultTargetStep(), BaseMessages.getString(PKG, "SwitchCaseMeta.TargetStream.Default.Description"), StreamIcon.TARGET, null));
}
}
return ioMeta;
}
use of org.pentaho.di.trans.step.errorhandling.Stream in project pentaho-kettle by pentaho.
the class MappingMeta method getStepIOMeta.
@Override
public StepIOMetaInterface getStepIOMeta() {
if (ioMeta == null) {
// TODO Create a dynamic StepIOMeta so that we can more easily manipulate the info streams?
ioMeta = new StepIOMeta(true, true, true, false, true, false);
for (MappingIODefinition def : inputMappings) {
if (isInfoMapping(def)) {
Stream stream = new Stream(StreamType.INFO, def.getInputStep(), BaseMessages.getString(PKG, "MappingMeta.InfoStream.Description"), StreamIcon.INFO, null);
ioMeta.addStream(stream);
}
}
}
return ioMeta;
}
use of org.pentaho.di.trans.step.errorhandling.Stream in project pentaho-kettle by pentaho.
the class MergeJoinMeta method clone.
public Object clone() {
MergeJoinMeta retval = (MergeJoinMeta) super.clone();
int nrKeys1 = keyFields1.length;
int nrKeys2 = keyFields2.length;
retval.allocate(nrKeys1, nrKeys2);
System.arraycopy(keyFields1, 0, retval.keyFields1, 0, nrKeys1);
System.arraycopy(keyFields2, 0, retval.keyFields2, 0, nrKeys2);
StepIOMetaInterface stepIOMeta = new StepIOMeta(true, true, false, false, false, false);
List<StreamInterface> infoStreams = getStepIOMeta().getInfoStreams();
for (StreamInterface infoStream : infoStreams) {
stepIOMeta.addStream(new Stream(infoStream));
}
retval.ioMeta = stepIOMeta;
return retval;
}
use of org.pentaho.di.trans.step.errorhandling.Stream in project pentaho-kettle by pentaho.
the class MergeRowsMeta method getStepIOMeta.
/**
* Returns the Input/Output metadata for this step.
*/
@Override
public StepIOMetaInterface getStepIOMeta() {
if (ioMeta == null) {
ioMeta = new StepIOMeta(true, true, false, false, false, false);
ioMeta.addStream(new Stream(StreamType.INFO, null, BaseMessages.getString(PKG, "MergeRowsMeta.InfoStream.FirstStream.Description"), StreamIcon.INFO, null));
ioMeta.addStream(new Stream(StreamType.INFO, null, BaseMessages.getString(PKG, "MergeRowsMeta.InfoStream.SecondStream.Description"), StreamIcon.INFO, null));
}
return ioMeta;
}
use of org.pentaho.di.trans.step.errorhandling.Stream in project pentaho-kettle by pentaho.
the class BaseStepMeta method clone.
/*
* (non-Javadoc)
*
* @see java.lang.Object#clone()
*/
@Override
public Object clone() {
try {
BaseStepMeta retval = (BaseStepMeta) super.clone();
// then the step references must be corrected.
if (ioMeta != null) {
StepIOMetaInterface stepIOMeta = new StepIOMeta(ioMeta.isInputAcceptor(), ioMeta.isOutputProducer(), ioMeta.isInputOptional(), ioMeta.isSortedDataRequired(), ioMeta.isInputDynamic(), ioMeta.isOutputDynamic());
List<StreamInterface> infoStreams = ioMeta.getInfoStreams();
for (StreamInterface infoStream : infoStreams) {
stepIOMeta.addStream(new Stream(infoStream));
}
List<StreamInterface> targetStreams = ioMeta.getTargetStreams();
for (StreamInterface targetStream : targetStreams) {
stepIOMeta.addStream(new Stream(targetStream));
}
retval.ioMeta = stepIOMeta;
}
return retval;
} catch (CloneNotSupportedException e) {
return null;
}
}
Aggregations