本文整理汇总了Java中org.pentaho.di.openerp.core.OpenERPHelper类的典型用法代码示例。如果您正苦于以下问题:Java OpenERPHelper类的具体用法?Java OpenERPHelper怎么用?Java OpenERPHelper使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
OpenERPHelper类属于org.pentaho.di.openerp.core包,在下文中一共展示了OpenERPHelper类的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: init
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public boolean init(StepMetaInterface smi, StepDataInterface sdi) {
meta = (OpenERPObjectOutputMeta) smi;
data = (OpenERPObjectOutputData) sdi;
if (super.init(smi, sdi)) {
try {
this.logDebug("Initializing OpenERP Session");
data.helper = new OpenERPHelper(meta.getDatabaseMeta());
data.helper.StartSession();
openerERPAdapter = data.helper.getAdapter(meta.getModelName());
return true;
} catch (Exception e) {
logError("An error occurred, processing will be stopped: "
+ e.getMessage());
setErrors(1);
stopAll();
}
}
return false;
}
示例2: init
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public boolean init(StepMetaInterface smi, StepDataInterface sdi) {
meta = (OpenERPObjectDeleteMeta) smi;
data = (OpenERPObjectDeleteData) sdi;
if (super.init(smi, sdi)) {
try {
this.logDebug("Initializing OpenERP Session");
data.helper = new OpenERPHelper(meta.getDatabaseMeta());
data.helper.StartSession();
return true;
} catch (Exception e) {
logError("An error occurred, processing will be stopped: "
+ e.getMessage());
setErrors(1);
stopAll();
}
}
return false;
}
示例3: init
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public boolean init(StepMetaInterface smi, StepDataInterface sdi) {
meta = (OpenERPObjectInputMeta) smi;
data = (OpenERPObjectInputData) sdi;
if (super.init(smi, sdi)) {
try {
this.logDebug("Initializing OpenERP Session");
data.helper = new OpenERPHelper(meta.getDatabaseMeta());
data.helper.StartSession();
return true;
} catch (Exception e) {
logError("An error occurred, processing will be stopped: " + e.getMessage());
setErrors(1);
stopAll();
}
}
return false;
}
示例4: getFields
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public void getFields(final RowMetaInterface row, final String origin,
final RowMetaInterface[] info, final StepMeta nextStep,
final VariableSpace space) throws KettleStepException {
if (databaseMeta == null)
throw new KettleStepException("There is no OpenERP database server connection defined");
final OpenERPHelper helper = new OpenERPHelper(databaseMeta);
try {
helper.StartSession();
final RowMetaInterface rowMeta = this.getRowMeta();
row.addRowMeta(rowMeta);
} catch (Exception e) {
throw new KettleStepException(e);
}
}
示例5: init
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public boolean init( StepMetaInterface smi, StepDataInterface sdi ) {
meta = (OpenERPObjectOutputMeta) smi;
data = (OpenERPObjectOutputData) sdi;
if ( super.init( smi, sdi ) ) {
try {
this.logDebug( "Initializing OpenERP Session" );
data.helper = new OpenERPHelper( meta.getDatabaseMeta() );
data.helper.StartSession();
openerERPAdapter = data.helper.getAdapter( meta.getModelName() );
return true;
} catch ( Exception e ) {
logError( "An error occurred, processing will be stopped: " + e.getMessage() );
setErrors( 1 );
stopAll();
}
}
return false;
}
示例6: init
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public boolean init( StepMetaInterface smi, StepDataInterface sdi ) {
meta = (OpenERPObjectDeleteMeta) smi;
data = (OpenERPObjectDeleteData) sdi;
if ( super.init( smi, sdi ) ) {
try {
this.logDebug( "Initializing OpenERP Session" );
data.helper = new OpenERPHelper( meta.getDatabaseMeta() );
data.helper.StartSession();
return true;
} catch ( Exception e ) {
logError( "An error occurred, processing will be stopped: " + e.getMessage() );
setErrors( 1 );
stopAll();
}
}
return false;
}
示例7: init
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public boolean init( StepMetaInterface smi, StepDataInterface sdi ) {
meta = (OpenERPObjectInputMeta) smi;
data = (OpenERPObjectInputData) sdi;
if ( super.init( smi, sdi ) ) {
try {
this.logDebug( "Initializing OpenERP Session" );
data.helper = new OpenERPHelper( meta.getDatabaseMeta() );
data.helper.StartSession();
return true;
} catch ( Exception e ) {
logError( "An error occurred, processing will be stopped: " + e.getMessage() );
setErrors( 1 );
stopAll();
}
}
return false;
}
示例8: getFields
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public void getFields( final RowMetaInterface row, final String origin, final RowMetaInterface[] info,
final StepMeta nextStep, final VariableSpace space, Repository repository, IMetaStore metaStore )
throws KettleStepException {
if ( databaseMeta == null ) {
throw new KettleStepException( "There is no OpenERP database server connection defined" );
}
final OpenERPHelper helper = new OpenERPHelper( databaseMeta );
try {
helper.StartSession();
final RowMetaInterface rowMeta = this.getRowMeta();
row.addRowMeta( rowMeta );
} catch ( Exception e ) {
throw new KettleStepException( e );
}
}
示例9: OpenERPObjectOutputData
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public OpenERPObjectOutputData(DatabaseMeta databaseMeta) throws KettleException {
super();
if(!(databaseMeta.getDatabaseInterface() instanceof OpenERPDatabaseMeta) ) {
throw new KettleException ("A connection of type OPENERP is expected");
}
helper = new OpenERPHelper(databaseMeta);
}
示例10: OpenERPObjectDeleteData
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public OpenERPObjectDeleteData(DatabaseMeta databaseMeta) throws KettleException {
super();
if(!(databaseMeta.getDatabaseInterface() instanceof OpenERPDatabaseMeta) ) {
throw new KettleException ("A connection of type OPENERP is expected");
}
helper = new OpenERPHelper(databaseMeta);
}
示例11: OpenERPObjectInputData
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public OpenERPObjectInputData(DatabaseMeta databaseMeta) throws KettleException {
super();
if(!(databaseMeta.getDatabaseInterface() instanceof OpenERPDatabaseMeta) ) {
throw new KettleException ("A connection of type OPENERP is expected");
}
helper = new OpenERPHelper(databaseMeta);
}
示例12: OpenERPObjectOutputData
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public OpenERPObjectOutputData( DatabaseMeta databaseMeta ) throws KettleException {
super();
if ( !( databaseMeta.getDatabaseInterface() instanceof OpenERPDatabaseMeta ) ) {
throw new KettleException( "A connection of type OPENERP is expected" );
}
helper = new OpenERPHelper( databaseMeta );
}
示例13: OpenERPObjectDeleteData
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public OpenERPObjectDeleteData( DatabaseMeta databaseMeta ) throws KettleException {
super();
if ( !( databaseMeta.getDatabaseInterface() instanceof OpenERPDatabaseMeta ) ) {
throw new KettleException( "A connection of type OPENERP is expected" );
}
helper = new OpenERPHelper( databaseMeta );
}
示例14: OpenERPObjectInputData
import org.pentaho.di.openerp.core.OpenERPHelper; //导入依赖的package包/类
public OpenERPObjectInputData( DatabaseMeta databaseMeta ) throws KettleException {
super();
if ( !( databaseMeta.getDatabaseInterface() instanceof OpenERPDatabaseMeta ) ) {
throw new KettleException( "A connection of type OPENERP is expected" );
}
helper = new OpenERPHelper( databaseMeta );
}