当前位置: 首页>>代码示例>>Java>>正文


Java StreamType类代码示例

本文整理汇总了Java中org.pentaho.di.trans.step.errorhandling.StreamInterface.StreamType的典型用法代码示例。如果您正苦于以下问题:Java StreamType类的具体用法?Java StreamType怎么用?Java StreamType使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


StreamType类属于org.pentaho.di.trans.step.errorhandling.StreamInterface包,在下文中一共展示了StreamType类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: readRep

import org.pentaho.di.trans.step.errorhandling.StreamInterface.StreamType; //导入依赖的package包/类
public void readRep(Repository rep, ObjectId id_step, List<DatabaseMeta> databases, Map<String, Counter> counters)
	throws KettleException
{
	try
	{
           int nrKeys = rep.countNrStepAttributes(id_step, "keys"); //$NON-NLS
           
		allocateKeys(nrKeys);
           
           for (int i=0;i<nrKeys;i++)
           {
               keyFields[i] = rep.getStepAttributeString(id_step, i, "keys"); //$NON-NLS-1$
           }

           long nInputStreams = rep.getStepAttributeInteger(id_step, "number_imput");
           for (int i = 0; i < nInputStreams; i++) {
               getStepIOMeta().addStream(new Stream(StreamType.INFO, null,
                   BaseMessages.getString(PKG, "MultiMergeJoin.InfoStream.Description"), 
                   StreamIcon.INFO, null));
           }
           List<StreamInterface> infoStreams = getStepIOMeta().getInfoStreams();
           
           for (int i=0; i < infoStreams.size(); i++)
		    infoStreams.get(i).setSubject( rep.getStepAttributeString (id_step, "step"+i) );  //$NON-NLS-1$

		joinType = rep.getStepAttributeString(id_step, "join_type"); //$NON-NLS-1$
	}
	catch(Exception e)
	{
		throw new KettleException(BaseMessages.getString(PKG, "MultiMergeJoinMeta.Exception.UnexpectedErrorReadingStepInfo"), e); //$NON-NLS-1$
	}
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:33,代码来源:MultiMergeJoinMeta.java

示例2: getMeta

import org.pentaho.di.trans.step.errorhandling.StreamInterface.StreamType; //导入依赖的package包/类
/**
* Get the meta data
* @param meta
*/
  private void getMeta(MultiMergeJoinMeta meta)
  {      
  	List<StreamInterface> infoStreams = meta.getStepIOMeta().getInfoStreams();

  	if (infoStreams.size()  == 0 ) {
  		if (inputSteps != null && inputSteps.length != 0) {
  		  for (int i = 0; i < inputSteps.length; i++)
  			    meta.getStepIOMeta().addStream(new Stream(StreamType.INFO, null,
  					    BaseMessages.getString(PKG, "MultiMergeJoin.InfoStream.Description"), 
  					    StreamIcon.INFO, null));
  			infoStreams = meta.getStepIOMeta().getInfoStreams();
  		}
  	}
  	else if(inputSteps != null && infoStreams.size() < inputSteps.length )
  	{
  		int requiredStreams =  inputSteps.length - infoStreams.size() ;
  		
  		for (int i = 0; i < requiredStreams; i++)
	    meta.getStepIOMeta().addStream(new Stream(StreamType.INFO, null,
			    BaseMessages.getString(PKG, "MultiMergeJoin.InfoStream.Description"), 
			    StreamIcon.INFO, null));
	infoStreams = meta.getStepIOMeta().getInfoStreams();
  	}
  	int streamCount = infoStreams.size();
  	meta.allocateInputSteps(streamCount);    
  	meta.allocateKeys(streamCount);
  	
  	for (int i = 0; i < streamCount; i++)
  	{
  		meta.getInputSteps()[i] = wInputStepArray[i].getText();
  		infoStreams.get(i).setStepMeta( transMeta.findStep( wInputStepArray[i].getText()) );
  		meta.getKeyFields()[i] = keyValTextBox[i].getText();
  	}
      meta.setJoinType(joinTypeCombo.getText());
  }
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:40,代码来源:MultiMergeJoinDialog.java

示例3: searchInfoAndTargetSteps

import org.pentaho.di.trans.step.errorhandling.StreamInterface.StreamType; //导入依赖的package包/类
@Override
public void searchInfoAndTargetSteps( List<StepMeta> steps ) {
  getStepIOMeta().getInfoStreams().clear();
  for ( int i = 0; i < inputSteps.length; i++ ) {
    String inputStepName = inputSteps[i];
    if ( i >= getStepIOMeta().getInfoStreams().size() ) {
      getStepIOMeta().addStream(
        new Stream( StreamType.INFO, StepMeta.findStep( steps, inputStepName ),
            BaseMessages.getString( PKG, "MultiMergeJoin.InfoStream.Description" ), StreamIcon.INFO, inputStepName ) );
    }
  }
}
 
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:13,代码来源:MultiMergeJoinMeta.java

示例4: readData

import org.pentaho.di.trans.step.errorhandling.StreamInterface.StreamType; //导入依赖的package包/类
private void readData(Node stepnode) throws KettleXMLException
{
	try
	{ 
           
           Node keysNode = XMLHandler.getSubNode(stepnode, "keys"); //$NON-NLS-1$
           
	    int nrKeys = XMLHandler.countNodes(keysNode, "key"); //$NON-NLS-1$
           
           allocateKeys(nrKeys);
           
           for (int i=0;i<nrKeys;i++) 
           {
               Node keynode = XMLHandler.getSubNodeByNr(keysNode, "key", i); //$NON-NLS-1$
               keyFields[i] = XMLHandler.getNodeValue(keynode);
           }

           int nInputStreams = Integer.parseInt(XMLHandler.getTagValue(stepnode, "number_input"));
           
           allocateInputSteps(nInputStreams);
           
           for (int i = 0; i < nInputStreams; i++) {
               getStepIOMeta().addStream(new Stream(StreamType.INFO, null,
                   BaseMessages.getString(PKG, "MultiMergeJoin.InfoStream.Description"), 
                   StreamIcon.INFO, null));
           }
           
           List<StreamInterface> infoStreams = getStepIOMeta().getInfoStreams();
           for (int i = 0; i < infoStreams.size(); i++)
           {
           	String stepName=XMLHandler.getTagValue(stepnode, "step"+i);
		    infoStreams.get(i).setSubject(stepName ); //$NON-NLS-1$
		    inputSteps[i]=stepName;
           }

		joinType = XMLHandler.getTagValue(stepnode, "join_type"); //$NON-NLS-1$
	}
	catch(Exception e)
	{
		throw new KettleXMLException(BaseMessages.getString(PKG, "MultiMergeJoinMeta.Exception.UnableToLoadStepInfo"), e); //$NON-NLS-1$
	}
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:43,代码来源:MultiMergeJoinMeta.java

示例5: setCandidateHopType

import org.pentaho.di.trans.step.errorhandling.StreamInterface.StreamType; //导入依赖的package包/类
public void setCandidateHopType(StreamType candidateHopType) {
	this.candidateHopType = candidateHopType;
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:4,代码来源:TransPainter.java

示例6: setCandidateHopType

import org.pentaho.di.trans.step.errorhandling.StreamInterface.StreamType; //导入依赖的package包/类
public void setCandidateHopType( StreamType candidateHopType ) {
  this.candidateHopType = candidateHopType;
}
 
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:4,代码来源:TransPainter.java

示例7: getCandidateHopType

import org.pentaho.di.trans.step.errorhandling.StreamInterface.StreamType; //导入依赖的package包/类
public StreamType getCandidateHopType() {
  return candidateHopType;
}
 
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:4,代码来源:TransPainter.java


注:本文中的org.pentaho.di.trans.step.errorhandling.StreamInterface.StreamType类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。