public void wizardFinished(WizardModelEvent e) { IExtensionHandler pluginHandler = (IExtensionHandler) data.getData("Plugin.handler"); AbstractMailboxImporter importer = null; Object[] args = new Object[] {data.getData("Location.destination"), data.getData("Location.source")}; try { IExtension extension = pluginHandler.getExtension((String) data.getData("Plugin.ID")); importer = (AbstractMailboxImporter) extension.instanciateExtension(args); } catch (PluginException e1) { if (Logging.DEBUG) e1.printStackTrace(); return; } ImportFolderCommandReference r = new ImportFolderCommandReference((IMailFolder) args[0], (File[]) args[1], importer); CommandProcessor.getInstance().addOp(new ImportMessageCommand(r)); }