當前位置: 首頁>>代碼示例>>Java>>正文


Java VariableSpace類代碼示例

本文整理匯總了Java中org.pentaho.di.core.variables.VariableSpace的典型用法代碼示例。如果您正苦於以下問題:Java VariableSpace類的具體用法?Java VariableSpace怎麽用?Java VariableSpace使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


VariableSpace類屬於org.pentaho.di.core.variables包,在下文中一共展示了VariableSpace類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: getFields

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
public void getFields(RowMetaInterface r, String origin, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space) {
    
    JSONArray transInfo = configInfo.getJSONArray(TRANS_INFO);
    for(JSONObject ti:transInfo.toArray(new JSONObject[]{})){
        //將轉換結果賦予新字段的,添加新字段
        if(ti.containsKey(RESULT_LATER)&&StringUtils.isNotBlank(ti.getString(RESULT_LATER))){
            addField(r,ti.getString(TRANS_FIELD)+ti.getString(RESULT_LATER),
                    ValueMeta.TYPE_STRING,ValueMeta.TRIM_TYPE_BOTH,origin,ti.getString(TRANS_FIELD)+"名稱");
        }
        if(RULE_TOJSON.equals(ti.getString(TRANS_RULE))){
            //轉換為JSON串
            addField(r,ti.getString(TRANS_FIELD),
                    ValueMeta.TYPE_STRING,ValueMeta.TRIM_TYPE_BOTH,origin,ti.getString(TRANS_FIELD));
        }
        if(RULE_TOTXT.equals(ti.getString(TRANS_RULE))){
            //轉換為JSON串
            addField(r,ti.getString(TRANS_FIELD),
                    ValueMeta.TYPE_STRING,ValueMeta.TRIM_TYPE_BOTH,origin,ti.getString(TRANS_FIELD));
        }
    }
    if(isHbjl()){
        addField(r,"GROUP_KEY",ValueMeta.TYPE_STRING,ValueMeta.TRIM_TYPE_BOTH,origin,"分組字段拚接出的key");
    }
}
 
開發者ID:majinju,項目名稱:KettleEasyExpand,代碼行數:25,代碼來源:DataTransform.java

示例2: getFields

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
/**
 * This method is called to determine the changes the step is making to the row-stream.
 * To that end a RowMetaInterface object is passed in, containing the row-stream structure as it is when entering
 * the step. This method must apply any changes the step makes to the row stream. Usually a step adds fields to the
 * row-stream.
 * 
 * @param inputRowMeta		the row structure coming in to the step
 * @param name 				the name of the step making the changes
 * @param info				row structures of any info steps coming in
 * @param nextStep			the description of a step this step is passing rows to
 * @param space				the variable space for resolving variables
 * @param repository		the repository instance optionally read from
 * @param metaStore			the metaStore to optionally read from
 */
 @Override
public void getFields(RowMetaInterface inputRowMeta, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore) throws KettleStepException{

   for ( int i = 0; i < fields.length; i++ ) {
     int type = fields[i].getType();
     if ( type == ValueMetaInterface.TYPE_NONE) type = ValueMetaInterface.TYPE_STRING;

     try {
       ValueMetaInterface v = ValueMetaFactory.createValueMeta( fields[i].getName(), type );
       v.setConversionMask( fields[i].getFormat() );
       v.setLength( fields[i].getLength() );
       v.setPrecision( fields[i].getPrecision() );
       v.setCurrencySymbol( fields[i].getCurrencySymbol() );
       v.setDecimalSymbol( fields[i].getDecimalSymbol() );
       v.setGroupingSymbol( fields[i].getGroupSymbol() );
       v.setTrimType( fields[i].getTrimType() );

       v.setOrigin( name );

       inputRowMeta.addValueMeta( v );
     } catch (KettlePluginException e) {
       throw new KettleStepException( e );
     }
   }
}
 
開發者ID:andtorg,項目名稱:sdmx-kettle,代碼行數:40,代碼來源:SdmxStepMeta.java

示例3: getFields

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
@Override
public void getFields(RowMetaInterface inputRowMeta, String name, RowMetaInterface[] info, StepMeta nextStep,
    VariableSpace space, Repository repository, IMetaStore metaStore) throws KettleStepException {
  
  // Optionally add a fields...
  //
  if (StringUtils.isNotEmpty(responseCodeField)) {
    ValueMetaInterface codeValue = new ValueMetaInteger(responseCodeField);
    codeValue.setLength(3);
    codeValue.setOrigin(name);
    inputRowMeta.addValueMeta(codeValue);
  }
  
  if (StringUtils.isNotEmpty(responseTimeField)) {
    ValueMetaInterface timeValue = new ValueMetaInteger(responseTimeField);
    timeValue.setLength(7);
    timeValue.setOrigin(name);
    inputRowMeta.addValueMeta(timeValue);
  }
}
 
開發者ID:mattcasters,項目名稱:pdi-hcp-plugin,代碼行數:21,代碼來源:HCPDeleteMeta.java

示例4: testGetUrl

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
@Test
public void testGetUrl() {
  VariableSpace space = new Variables();
  space.setVariable("SERVER", "hcpdemo.com");
  space.setVariable("PORT", "8000");
  space.setVariable("NAMESPACE", "hcp-demo");
  space.setVariable("TENANT", "pentaho");
  
  HCPConnection connection = new HCPConnection();
  connection.setServer("${SERVER}");
  connection.setPort("${PORT}");
  connection.setNamespace("${NAMESPACE}");
  connection.setTenant("${TENANT}");
  
  String restUrl = connection.getRestUrl(space);
  assertEquals("http://pentaho.hcp-demo.hcpdemo.com:8000/rest", restUrl);    
}
 
開發者ID:mattcasters,項目名稱:pdi-hcp-plugin,代碼行數:18,代碼來源:HCPConnectionTest.java

示例5: getStage

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
/**
 * Gets the Snowflake stage name based on the configured metadata
 * @param space The variable space
 * @return The Snowflake stage name to use
 */
public String getStage( VariableSpace space ) {
  if ( locationType.equals( LOCATION_TYPE_CODES[LOCATION_TYPE_USER] ) ) {
    return "@~/" + space.environmentSubstitute( targetTable );
  } else if ( locationType.equals( LOCATION_TYPE_CODES[LOCATION_TYPE_TABLE] ) ) {
    if ( !Const.isEmpty( space.environmentSubstitute( targetSchema ) ) ) {
      return "@" + space.environmentSubstitute( targetSchema ) + ".%" + space.environmentSubstitute( targetTable );
    } else {
      return "@%" + space.environmentSubstitute( targetTable );
    }
  } else if ( locationType.equals( LOCATION_TYPE_CODES[LOCATION_TYPE_INTERNAL_STAGE] ) ) {
    if ( !Const.isEmpty( space.environmentSubstitute( targetSchema ) ) ) {
      return "@" + space.environmentSubstitute( targetSchema ) + "." + space.environmentSubstitute( stageName );
    } else {
      return "@" + space.environmentSubstitute( stageName );
    }
  }
  return null;
}
 
開發者ID:inquidia,項目名稱:PentahoSnowflakePlugin,代碼行數:24,代碼來源:SnowflakeBulkLoaderMeta.java

示例6: getFields

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
@Override
public void getFields( RowMetaInterface inputRowMeta, String name, RowMetaInterface[] info, StepMeta nextStep,
    VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException {
  super.getFields( inputRowMeta, name, info, nextStep, space, repository, metaStore );
  if ( nextStep != null ) {
    if ( nextStep.equals( organizationStepMeta ) ) {
      prepareExecutionResultsOrganization( inputRowMeta, space );
    } else if ( nextStep.equals( organizationTagStepMeta ) ) {
      prepareExecutionResultsOrganizationTag( inputRowMeta, space );
    } else if ( nextStep.equals( organizationFieldStepMeta ) ) {
      prepareExecutionResultsOrganizationField( inputRowMeta, space );
    } else if ( nextStep.equals( organizationDomainStepMeta ) ) {
      prepareExecutionResultsOrganizationDomain( inputRowMeta, space );
    }
  }
}
 
開發者ID:matthewtckr,項目名稱:pdi-zendesk-plugin,代碼行數:17,代碼來源:ZendeskInputOrganizationsMeta.java

示例7: prepareExecutionResultsArticle

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
private void prepareExecutionResultsArticle( RowMetaInterface inputRowMeta, VariableSpace space ) throws KettleStepException {
  inputRowMeta.clear();
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getArticleIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getArticleUrlFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getArticleTitleFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getArticleBodyFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getLocaleFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSourceLocaleFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getAuthorIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCommentsDisabledFieldname() ), ValueMetaInterface.TYPE_BOOLEAN );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getOutdatedFieldname() ), ValueMetaInterface.TYPE_BOOLEAN );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getLabelsFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getDraftFieldname() ), ValueMetaInterface.TYPE_BOOLEAN );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getPromotedFieldname() ), ValueMetaInterface.TYPE_BOOLEAN );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getPositionFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getVoteSumFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getVoteCountFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSectionIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCreatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getUpdatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
}
 
開發者ID:matthewtckr,項目名稱:pdi-zendesk-plugin,代碼行數:22,代碼來源:ZendeskInputHCArticleMeta.java

示例8: prepareExecutionResultsTranslation

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
private void prepareExecutionResultsTranslation( RowMetaInterface inputRowMeta, VariableSpace space ) throws KettleStepException {
  inputRowMeta.clear();
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getArticleIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationUrlFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationHtmlUrlFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationSourceIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationSourceTypeFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationLocaleFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationTitleFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationBodyFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationOutdatedFieldname() ), ValueMetaInterface.TYPE_BOOLEAN );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationDraftFieldname() ), ValueMetaInterface.TYPE_BOOLEAN );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationCreatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationUpdatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationUpdatedByIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTranslationCreatedByIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
}
 
開發者ID:matthewtckr,項目名稱:pdi-zendesk-plugin,代碼行數:19,代碼來源:ZendeskInputHCArticleMeta.java

示例9: getFields

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
@Override
public void getFields( RowMetaInterface inputRowMeta, String name, RowMetaInterface[] info, StepMeta nextStep,
    VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException {
  super.getFields( inputRowMeta, name, info, nextStep, space, repository, metaStore );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTicketFieldIdFieldname() ),
    ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTicketFieldUrlFieldname() ),
    ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTicketFieldTypeFieldname() ),
    ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTicketFieldTitleFieldname() ),
    ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTicketFieldActiveFieldname() ),
    ValueMetaInterface.TYPE_BOOLEAN );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTicketFieldRequiredFieldname() ),
    ValueMetaInterface.TYPE_BOOLEAN );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTicketFieldVisibleEndUsersFieldname() ),
    ValueMetaInterface.TYPE_BOOLEAN );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCreatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getUpdatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
}
 
開發者ID:matthewtckr,項目名稱:pdi-zendesk-plugin,代碼行數:22,代碼來源:ZendeskInputTicketFieldsMeta.java

示例10: getFields

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
@Override
public void getFields( RowMetaInterface inputRowMeta, String name, RowMetaInterface[] info, StepMeta nextStep,
    VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException {
  super.getFields( inputRowMeta, name, info, nextStep, space, repository, metaStore );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSectionIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSectionUrlFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSectionNameFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCategoryIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getLocaleFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSourceLocaleFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSectionHtmlUrlFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getOutdatedFieldname() ), ValueMetaInterface.TYPE_BOOLEAN );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getPositionFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCreatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getUpdatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
}
 
開發者ID:matthewtckr,項目名稱:pdi-zendesk-plugin,代碼行數:17,代碼來源:ZendeskInputHCSectionMeta.java

示例11: getFields

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
@Override
public void getFields( RowMetaInterface inputRowMeta, String name, RowMetaInterface[] info, StepMeta nextStep,
    VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException {
  if ( nextStep != null ) {
    if ( nextStep.equals( ticketOverviewStepMeta ) ) {
      prepareExecutionResultsTicketOverview( inputRowMeta, space );
    } else if ( nextStep.equals( ticketCommentsStepMeta ) ) {
      prepareExecutionResultsTicketComments( inputRowMeta, space );
    } else if ( nextStep.equals( ticketCustomFieldsStepMeta ) ) {
      prepareExecutionResultsTicketCustomFields( inputRowMeta, space );
    } else if ( nextStep.equals( ticketTagsStepMeta ) ) {
      prepareExecutionResultsTicketTags( inputRowMeta, space );
    } else if ( nextStep.equals( ticketCollaboratorsStepMeta ) ) {
      prepareExecutionResultsTicketCollaborators( inputRowMeta, space );
    }
  }
}
 
開發者ID:matthewtckr,項目名稱:pdi-zendesk-plugin,代碼行數:18,代碼來源:ZendeskInputTicketAuditMeta.java

示例12: prepareExecutionResultsTicketOverview

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
private void prepareExecutionResultsTicketOverview( RowMetaInterface inputRowMeta, VariableSpace space ) throws KettleStepException {
  inputRowMeta.clear();
  addFieldToRow( inputRowMeta, getTicketIdFieldname(), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getAuditIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getAuditRownumFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCreatedTimeFieldname() ), ValueMetaInterface.TYPE_DATE );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getOrganizationIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getRequesterIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getAssigneeIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getGroupIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSubjectFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getStatusFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getPriorityFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getChannelFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTypeFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSatisfactionFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getLocaleFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getDueAtFieldname() ), ValueMetaInterface.TYPE_DATE );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSatisfactionCommentFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getFormIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getBrandIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
}
 
開發者ID:matthewtckr,項目名稱:pdi-zendesk-plugin,代碼行數:23,代碼來源:ZendeskInputTicketAuditMeta.java

示例13: getFields

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
@Override
public void getFields( RowMetaInterface inputRowMeta, String name, RowMetaInterface[] info, StepMeta nextStep,
    VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException {
  super.getFields( inputRowMeta, name, info, nextStep, space, repository, metaStore );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCategoryIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCategoryUrlFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCategoryNameFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getDescriptionFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getLocaleFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSourceLocaleFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCategoryHtmlUrlFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getOutdatedFieldname() ), ValueMetaInterface.TYPE_BOOLEAN );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getPositionFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCreatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getUpdatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
}
 
開發者ID:matthewtckr,項目名稱:pdi-zendesk-plugin,代碼行數:17,代碼來源:ZendeskInputHCCategoryMeta.java

示例14: getFields

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
@Override
public void getFields( RowMetaInterface inputRowMeta, String name, RowMetaInterface[] info, StepMeta nextStep,
    VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException {
  super.getFields( inputRowMeta, name, info, nextStep, space, repository, metaStore );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSuspendedTicketIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSuspendedTicketUrlFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getAuthorFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getSubjectFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getContentFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCauseFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getMessageIdFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getTicketIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getRecipientFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getCreatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getUpdatedAtFieldname() ), ValueMetaInterface.TYPE_DATE );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getViaFieldname() ), ValueMetaInterface.TYPE_STRING );
  addFieldToRow( inputRowMeta, space.environmentSubstitute( getBrandIdFieldname() ), ValueMetaInterface.TYPE_INTEGER );
}
 
開發者ID:matthewtckr,項目名稱:pdi-zendesk-plugin,代碼行數:19,代碼來源:ZendeskInputSuspendedTicketsMeta.java

示例15: getFields

import org.pentaho.di.core.variables.VariableSpace; //導入依賴的package包/類
public void getFields(RowMetaInterface r, String origin, RowMetaInterface[] info, StepMeta nextStep,
                      VariableSpace space, Repository repository, IMetaStore metaStore) {

    for (SocrataTextFileField field : outputFields) {
        ValueMetaInterface v = r.searchValueMeta( field.getName() );
        if ( v != null ) {
            v.setLength(field.getLength());
            v.setPrecision(field.getPrecision());
            v.setConversionMask(field.getFormat());
            v.setDecimalSymbol(field.getDecimalSymbol());
            v.setGroupingSymbol(field.getGroupingSymbol());
            v.setCurrencySymbol(field.getCurrencySymbol());
            v.setTrimType( field.getTrimType() );

            // enable output padding by default to be compatible with v2.5.x
            //
            v.setOutputPaddingEnabled( true );
        }
    }
}
 
開發者ID:socrata,項目名稱:socrata-kettle,代碼行數:21,代碼來源:SocrataPluginMeta.java


注:本文中的org.pentaho.di.core.variables.VariableSpace類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。