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


Java Props.init方法代码示例

本文整理汇总了Java中org.pentaho.di.core.Props.init方法的典型用法代码示例。如果您正苦于以下问题:Java Props.init方法的具体用法?Java Props.init怎么用?Java Props.init使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.pentaho.di.core.Props的用法示例。


在下文中一共展示了Props.init方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: SQLModelGenerator

import org.pentaho.di.core.Props; //导入方法依赖的package包/类
public SQLModelGenerator( String modelName, String connectionName, int[] columnTypes, String[] columnNames,
    String query, Boolean securityEnabled, List<String> users, List<String> roles, int defaultAcls, String createdBy ) {
  if ( !Props.isInitialized() ) {
    Props.init( Props.TYPE_PROPERTIES_EMPTY );
  }
  this.query = query;
  this.connectionName = connectionName;
  this.columnTypes = columnTypes;
  this.columnNames = columnNames;
  this.modelName = modelName;
  this.securityEnabled = securityEnabled;
  this.users = users;
  this.roles = roles;
  this.defaultAcls = defaultAcls;
  this.createdBy = createdBy;
}
 
开发者ID:pentaho,项目名称:pentaho-metadata,代码行数:17,代码来源:SQLModelGenerator.java

示例2: testToLegacy

import org.pentaho.di.core.Props; //导入方法依赖的package包/类
@Test
public void testToLegacy() throws ObjectAlreadyExistsException {
  if ( !Props.isInitialized() ) {
    Props.init( Props.TYPE_PROPERTIES_EMPTY );
  }
  SchemaMeta meta = ThinModelConverter.convertToLegacy( domain );
  String locale = Locale.getDefault().toString();
  // verify conversion worked.
  BusinessModel model = meta.findModel( "MODEL_1" );
  assertNotNull( model );
  String local = model.getName( locale );
  assertEquals( "newdatasource", model.getName( locale ) );
  BusinessCategory cat =  model.getRootCategory().findBusinessCategory( Settings.getBusinessCategoryIDPrefix() + "newdatasource" );
  assertNotNull( cat );
  assertEquals( "newdatasource", cat.getName( locale ) );
  assertEquals( 1, cat.getBusinessColumns().size() );
  // this tests the inheritance of physical cols made it through
  BusinessColumn col = cat.getBusinessColumn( 0 );
  assertEquals( "CUSTOMERNAME", col.getName( locale ) );
  assertNotNull( col.getBusinessTable() );
  assertEquals( "LOGICAL_TABLE_1", col.getBusinessTable().getId() );
  assertEquals( col.getDataType(), DataTypeSettings.STRING );
  assertEquals( "select customername from customers where customernumber < 171", col.getBusinessTable().getTargetTable() );
  assertEquals( "select customername from customers where customernumber < 171", col.getPhysicalColumn().getTable().getTargetTable() );
  assertEquals( "CUSTOMERNAME", col.getPhysicalColumn().getFormula() );
  assertEquals( false, col.getPhysicalColumn().isExact() );
}
 
开发者ID:pentaho,项目名称:pentaho-metadata,代码行数:28,代码来源:SQLModelGeneratorIT.java

示例3: init

import org.pentaho.di.core.Props; //导入方法依赖的package包/类
@BeforeClass
public static void init() throws Exception {
  KettleClientEnvironment.init();
  PluginRegistry.addPluginType( StepPluginType.getInstance() );
  PluginRegistry.init();
  if ( !Props.isInitialized() ) {
    Props.init( 0 );
  }
}
 
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:10,代码来源:SafeStopTest.java

示例4: testShouldOverwrite

import org.pentaho.di.core.Props; //导入方法依赖的package包/类
@Test
public void testShouldOverwrite() {
  assertTrue( meta.shouldOverwrite( null, null, null, null ) );
  Props.init( Props.TYPE_PROPERTIES_EMPTY );
  assertTrue( meta.shouldOverwrite( null, Props.getInstance(), "message", "remember" ) );

  Props.getInstance().setProperty( Props.STRING_ASK_ABOUT_REPLACING_DATABASES, "Y" );
  OverwritePrompter prompter = mock( OverwritePrompter.class );
  when( prompter.overwritePrompt( "message", "remember", Props.STRING_ASK_ABOUT_REPLACING_DATABASES ) )
    .thenReturn( false );
  assertFalse( meta.shouldOverwrite( prompter, Props.getInstance(), "message", "remember" ) );
}
 
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:13,代码来源:AbstractMetaTest.java

示例5: init

import org.pentaho.di.core.Props; //导入方法依赖的package包/类
@BeforeClass
public static void init() throws Exception {
  if ( !KettleClientEnvironment.isInitialized() ) {
    KettleClientEnvironment.init();
  }
  PluginRegistry.addPluginType( StepPluginType.getInstance() );
  PluginRegistry.init();
  if ( !Props.isInitialized() ) {
    Props.init( 0 );
  }
}
 
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:12,代码来源:TransMetaConverterTest.java

示例6: InlineEtlModelGenerator

import org.pentaho.di.core.Props; //导入方法依赖的package包/类
public InlineEtlModelGenerator() {
  if ( !Props.isInitialized() ) {
    Props.init( Props.TYPE_PROPERTIES_EMPTY );
  }
}
 
开发者ID:pentaho,项目名称:pentaho-metadata,代码行数:6,代码来源:InlineEtlModelGenerator.java

示例7: environmentInit

import org.pentaho.di.core.Props; //导入方法依赖的package包/类
public static void environmentInit( final IPentahoSession session ) throws KettleException {
  // init kettle without simplejndi
  KettleEnvironment.init( false );
  Props.init( null );
}
 
开发者ID:pentaho,项目名称:pdi-platform-plugin,代码行数:6,代码来源:KettleSystemListener.java


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