本文整理匯總了Java中org.pentaho.di.trans.step.StepMetaInterface.getDialogClassName方法的典型用法代碼示例。如果您正苦於以下問題:Java StepMetaInterface.getDialogClassName方法的具體用法?Java StepMetaInterface.getDialogClassName怎麽用?Java StepMetaInterface.getDialogClassName使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類org.pentaho.di.trans.step.StepMetaInterface
的用法示例。
在下文中一共展示了StepMetaInterface.getDialogClassName方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: getStepEntryDialog
import org.pentaho.di.trans.step.StepMetaInterface; //導入方法依賴的package包/類
public StepDialogInterface getStepEntryDialog(StepMetaInterface stepMeta, TransMeta transMeta,
String stepName)
{
String dialogClassName = stepMeta.getDialogClassName();
try
{
Class<?> dialogClass;
Class<?>[] paramClasses = new Class[] { spoon.getShell().getClass(), Object.class,
TransMeta.class, String.class };
Object[] paramArgs = new Object[] { spoon.getShell(), stepMeta, transMeta, stepName };
Constructor<?> dialogConstructor;
dialogClass = stepMeta.getClass().getClassLoader().loadClass(dialogClassName);
dialogConstructor = dialogClass.getConstructor(paramClasses);
return (StepDialogInterface) dialogConstructor.newInstance(paramArgs);
} catch (Throwable t)
{
spoon.getLog().logError(spoon.toString(), "Could not create dialog for " + dialogClassName, t);
}
return null;
}
示例2: getStepEntryDialog
import org.pentaho.di.trans.step.StepMetaInterface; //導入方法依賴的package包/類
public StepDialogInterface getStepEntryDialog(StepMetaInterface stepMeta, TransMeta transMeta,
String stepName) throws KettleException
{
String dialogClassName = stepMeta.getDialogClassName();
Class<?> dialogClass;
Class<?>[] paramClasses = new Class[] { Shell.class, Object.class, TransMeta.class, String.class };
Object[] paramArgs = new Object[] { spoon.getShell(), stepMeta, transMeta, stepName };
Constructor<?> dialogConstructor;
try
{
dialogClass = stepMeta.getClass().getClassLoader().loadClass(dialogClassName);
dialogConstructor = dialogClass.getConstructor(paramClasses);
return (StepDialogInterface) dialogConstructor.newInstance(paramArgs);
} catch (Exception e)
{
// try the old way for compatibility
Method method = null;
try {
Class<?> sig[] = new Class[] {Shell.class, StepMetaInterface.class, TransMeta.class, String.class};
method = stepMeta.getClass().getDeclaredMethod( "getDialog", sig );
if( method != null ) {
return (StepDialogInterface) method.invoke( stepMeta, new Object[] { spoon.getShell(), stepMeta, transMeta, stepName } );
}
} catch (Throwable t) {
}
throw new KettleException(e);
}
}
示例3: getStepEntryDialog
import org.pentaho.di.trans.step.StepMetaInterface; //導入方法依賴的package包/類
public StepDialogInterface getStepEntryDialog(StepMetaInterface stepMeta, TransMeta transMeta,
String stepName) throws KettleException
{
String dialogClassName = stepMeta.getDialogClassName();
Class<?> dialogClass;
Class<?>[] paramClasses = new Class[] { Shell.class, Object.class, TransMeta.class, String.class };
Object[] paramArgs = new Object[] { spoon.getShell(), stepMeta, transMeta, stepName };
Constructor<?> dialogConstructor;
try
{
dialogClass = stepMeta.getClass().getClassLoader().loadClass(dialogClassName);
dialogConstructor = dialogClass.getConstructor(paramClasses);
return (StepDialogInterface) dialogConstructor.newInstance(paramArgs);
} catch (Exception e)
{
// try the old way for compatibility
Method method = null;
try {
Class<?> sig[] = new Class[] {Shell.class, StepMetaInterface.class, TransMeta.class, String.class};
method = stepMeta.getClass().getDeclaredMethod( "getDialog", sig );
if( method != null ) {
return (StepDialogInterface) method.invoke( stepMeta, new Object[] { spoon.getShell(), stepMeta, transMeta, stepName } );
}
} catch (Throwable t) {
}
throw new KettleException(e);
}
}