fixing #5341 and colouring for cache relevant fields #4915 and #4944
[taxeditor.git] / eu.etaxonomy.taxeditor.store / src / main / java / eu / etaxonomy / taxeditor / featuretree / AvailableFeaturesWizard.java
1 // $Id$
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 */
10
11 package eu.etaxonomy.taxeditor.featuretree;
12
13 import java.util.Set;
14
15 import org.eclipse.jface.wizard.Wizard;
16
17 import eu.etaxonomy.cdm.model.description.Feature;
18 import eu.etaxonomy.cdm.model.description.FeatureTree;
19
20 /**
21 * <p>AvailableFeaturesWizard class.</p>
22 *
23 * @author n.hoffmann
24 * @created Aug 5, 2010
25 * @version 1.0
26 */
27 public class AvailableFeaturesWizard extends Wizard {
28
29 private FeatureTree featureTree;
30
31 private AvailableFeaturesWizardPage page;
32
33 private Set<Feature> additionalFeatures;
34
35 /**
36 * <p>Constructor for AvailableFeaturesWizard.</p>
37 *
38 * @param featureTree a {@link eu.etaxonomy.cdm.model.description.FeatureTree} object.
39 */
40 public AvailableFeaturesWizard(FeatureTree featureTree){
41 this.featureTree = featureTree;
42 }
43
44 /** {@inheritDoc} */
45 @Override
46 public void addPages() {
47 page = new AvailableFeaturesWizardPage(featureTree);
48 addPage(page);
49 }
50
51 /** {@inheritDoc} */
52 @Override
53 public boolean performFinish() {
54 additionalFeatures = page.getSelectedFeatures();
55 return additionalFeatures.size() > 0;
56 }
57
58 /**
59 * <p>Getter for the field <code>additionalFeatures</code>.</p>
60 *
61 * @return a {@link java.util.Set} object.
62 */
63 public Set<Feature> getAdditionalFeatures() {
64 return additionalFeatures;
65 }
66 }