Revision 707b6237
Added by Niels Hoffmann over 12 years ago
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/io/wizard/TcsExportWizard.java | ||
---|---|---|
1 | 1 |
// $Id$ |
2 | 2 |
/** |
3 |
* Copyright (C) 2007 EDIT |
|
4 |
* European Distributed Institute of Taxonomy |
|
5 |
* http://www.e-taxonomy.eu |
|
6 |
* |
|
7 |
* The contents of this file are subject to the Mozilla Public License Version 1.1 |
|
8 |
* See LICENSE.TXT at the top of this package for the full license terms. |
|
9 |
*/ |
|
3 |
* Copyright (C) 2007 EDIT
|
|
4 |
* European Distributed Institute of Taxonomy
|
|
5 |
* http://www.e-taxonomy.eu
|
|
6 |
*
|
|
7 |
* The contents of this file are subject to the Mozilla Public License Version 1.1
|
|
8 |
* See LICENSE.TXT at the top of this package for the full license terms.
|
|
9 |
*/
|
|
10 | 10 |
|
11 | 11 |
package eu.etaxonomy.taxeditor.io.wizard; |
12 | 12 |
|
... | ... | |
19 | 19 |
import eu.etaxonomy.taxeditor.store.CdmStore; |
20 | 20 |
|
21 | 21 |
/** |
22 |
* <p>TcsExportWizard class.</p> |
|
23 |
* |
|
22 |
* <p> |
|
23 |
* TcsExportWizard class. |
|
24 |
* </p> |
|
25 |
* |
|
24 | 26 |
* @author n.hoffmann |
25 | 27 |
* @created 15.06.2009 |
26 | 28 |
* @version 1.0 |
27 | 29 |
*/ |
28 |
public class TcsExportWizard extends AbstractExportWizard<TcsXmlExportConfigurator> {
|
|
29 |
private static final String TCS_EXPORT = "TCS_EXPORT";
|
|
30 |
public class TcsExportWizard extends |
|
31 |
AbstractExportWizard<TcsXmlExportConfigurator> {
|
|
30 | 32 |
private TcsXmlExportConfigurator configurator; |
31 | 33 |
private ExportToFileDestinationWizardPage page; |
32 | 34 |
|
33 |
/* (non-Javadoc) |
|
35 |
/* |
|
36 |
* (non-Javadoc) |
|
37 |
* |
|
34 | 38 |
* @see org.eclipse.jface.wizard.Wizard#performFinish() |
35 | 39 |
*/ |
36 | 40 |
/** {@inheritDoc} */ |
37 | 41 |
@Override |
38 | 42 |
public boolean performFinish() { |
39 |
String urlString = page.getFolderText() + File.separator + page.getExportFileName(); |
|
40 |
|
|
43 |
String urlString = page.getFolderText() + File.separator |
|
44 |
+ page.getExportFileName(); |
|
45 |
|
|
41 | 46 |
configurator.setDestination(new File(urlString)); |
42 |
|
|
47 |
|
|
43 | 48 |
CdmStore.getExportManager().run(configurator); |
44 |
|
|
49 |
|
|
45 | 50 |
return true; |
46 | 51 |
} |
47 | 52 |
|
48 |
/* (non-Javadoc) |
|
49 |
* @see org.eclipse.ui.IWorkbenchWizard#init(org.eclipse.ui.IWorkbench, org.eclipse.jface.viewers.IStructuredSelection) |
|
53 |
/* |
|
54 |
* (non-Javadoc) |
|
55 |
* |
|
56 |
* @see org.eclipse.ui.IWorkbenchWizard#init(org.eclipse.ui.IWorkbench, |
|
57 |
* org.eclipse.jface.viewers.IStructuredSelection) |
|
50 | 58 |
*/ |
51 | 59 |
/** {@inheritDoc} */ |
52 | 60 |
public void init(IWorkbench workbench, IStructuredSelection selection) { |
53 | 61 |
configurator = TcsXmlExportConfigurator.NewInstance(null, null); |
54 | 62 |
} |
55 | 63 |
|
56 |
/* (non-Javadoc) |
|
64 |
/* |
|
65 |
* (non-Javadoc) |
|
66 |
* |
|
57 | 67 |
* @see eu.etaxonomy.taxeditor.io.AbstractExportWizard#getConfigurator() |
58 | 68 |
*/ |
59 | 69 |
/** {@inheritDoc} */ |
... | ... | |
62 | 72 |
return configurator; |
63 | 73 |
} |
64 | 74 |
|
65 |
/* (non-Javadoc) |
|
75 |
/* |
|
76 |
* (non-Javadoc) |
|
77 |
* |
|
66 | 78 |
* @see eu.etaxonomy.taxeditor.io.AbstractExportWizard#addPages() |
67 | 79 |
*/ |
68 | 80 |
/** {@inheritDoc} */ |
69 | 81 |
@Override |
70 | 82 |
public void addPages() { |
71 | 83 |
super.addPages(); |
72 |
|
|
84 |
|
|
73 | 85 |
page = ExportToFileDestinationWizardPage.Tcs(); |
74 | 86 |
addPage(page); |
75 | 87 |
} |
76 |
|
|
77 |
|
|
88 |
|
|
78 | 89 |
} |
Also available in: Unified diff
Merged with trunk