use of org.pentaho.di.plugins.fileopensave.dialog.FileOpenSaveDialog in project pentaho-kettle by pentaho.
the class FileOpenSaveExtensionPoint method callExtensionPoint.
@Override
public void callExtensionPoint(LogChannelInterface logChannelInterface, Object o) throws KettleException {
FileDialogOperation fileDialogOperation = (FileDialogOperation) o;
final FileOpenSaveDialog fileOpenSaveDialog = new FileOpenSaveDialog(spoonSupplier.get().getShell(), WIDTH, HEIGHT, logChannelInterface);
resolveProvider(fileDialogOperation);
fileOpenSaveDialog.open(fileDialogOperation);
fileDialogOperation.setPath(null);
fileDialogOperation.setFilename(null);
fileDialogOperation.setConnection(null);
if (!Utils.isEmpty(fileOpenSaveDialog.getProvider())) {
try {
FileProvider fileProvider = providerService.get(fileOpenSaveDialog.getProvider());
fileProvider.setFileProperties(fileOpenSaveDialog, fileDialogOperation);
} catch (InvalidFileProviderException e) {
throw new KettleException(e);
}
}
}
Aggregations