3 * Copyright (C) 2007 EDIT
4 * European Distributed Institute of Taxonomy
5 * http://www.e-taxonomy.eu
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.
11 package eu
.etaxonomy
.taxeditor
.dialogs
.filteredSelection
;
13 import java
.util
.UUID
;
15 import org
.eclipse
.swt
.widgets
.Composite
;
16 import org
.eclipse
.swt
.widgets
.Control
;
17 import org
.eclipse
.swt
.widgets
.Shell
;
19 import eu
.etaxonomy
.cdm
.api
.conversation
.ConversationHolder
;
20 import eu
.etaxonomy
.cdm
.model
.taxon
.Classification
;
21 import eu
.etaxonomy
.taxeditor
.editor
.newWizard
.AbstractNewEntityWizard
;
22 import eu
.etaxonomy
.taxeditor
.store
.CdmStore
;
25 * <p>FilteredClassificationSelectionDialog class.</p>
28 * @created Sep 21, 2009
31 public class FilteredClassificationSelectionDialog
extends
32 AbstractFilteredCdmResourceSelectionDialog
<Classification
> {
37 * @param shell a {@link org.eclipse.swt.widgets.Shell} object.
38 * @param conversation a {@link eu.etaxonomy.cdm.api.conversation.ConversationHolder} object.
39 * @return a {@link eu.etaxonomy.cdm.model.taxon.TaxonomicTree} object.
41 public static Classification
select(Shell shell
, ConversationHolder conversation
) {
42 FilteredClassificationSelectionDialog dialog
= new FilteredClassificationSelectionDialog(shell
, conversation
,
43 "Choose a Classification", false, "", null);
44 return getSelectionFromDialog(dialog
);
48 * <p>Constructor for FilteredClassificationSelectionDialog.</p>
50 * @param shell a {@link org.eclipse.swt.widgets.Shell} object.
51 * @param title a {@link java.lang.String} object.
52 * @param multi a boolean.
53 * @param settings a {@link java.lang.String} object.
54 * @param conversation a {@link eu.etaxonomy.cdm.api.conversation.ConversationHolder} object.
55 * @param classification a {@link eu.etaxonomy.cdm.model.taxon.TaxonomicTree} object.
57 protected FilteredClassificationSelectionDialog(Shell shell
, ConversationHolder conversation
, String title
,
58 boolean multi
, String settings
, Classification classification
) {
59 super(shell
, conversation
, title
, multi
, settings
, classification
);
63 * @see org.eclipse.ui.dialogs.FilteredItemsSelectionDialog#createExtendedContentArea(org.eclipse.swt.widgets.Composite)
67 protected Control
createExtendedContentArea(Composite parent
) {
68 // TODO Auto-generated method stub
73 * @see eu.etaxonomy.taxeditor.dialogs.AbstractFilteredCdmResourceSelectionDialog#getPersistentObject(java.util.UUID)
77 protected Classification
getPersistentObject(UUID cdmUuid
) {
78 return CdmStore
.getClassificationService().getClassificationByUuid(cdmUuid
);
82 * @see eu.etaxonomy.taxeditor.dialogs.AbstractFilteredCdmResourceSelectionDialog#initModel()
86 protected void initModel() {
87 model
= CdmStore
.getClassificationService().getUuidAndTitleCache();
92 protected AbstractNewEntityWizard
getNewEntityWizard() {
93 // TODO Auto-generated method stub
99 protected String
getNewWizardLinkText() {
100 // TODO Auto-generated method stub