}
private BaseStepGenericXulDialog createDialog()
throws ReportDataFactoryException
{
final StepMeta step = findInputStep();
if (step == null)
{
return null;
}
// Render datasource specific dialog for editing step details...
try
{
final String dlgClassName = step.getStepMetaInterface().getDialogClassName().replace("Dialog", "XulDialog");
ClassLoader pluginClassLoader = step.getStepMetaInterface().getClass().getClassLoader();
final Class<BaseStepGenericXulDialog> dialog =
(Class<BaseStepGenericXulDialog>) Class.forName(dlgClassName, true, pluginClassLoader);
final Constructor<BaseStepGenericXulDialog> constructor =
dialog.getDeclaredConstructor(Object.class, BaseStepMeta.class, TransMeta.class, String.class);
return constructor.newInstance(null, step.getStepMetaInterface(),
step.getParentTransMeta(), EmbeddedKettleDataFactoryMetaData.DATA_CONFIGURATION_STEP);
}
catch (Exception e)
{
logger.error("Critical error attempting to dynamically create dialog. This datasource will not be available.", e);