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
.cdm
.api
.service
;
13 import java
.util
.HashSet
;
14 import java
.util
.List
;
16 import java
.util
.UUID
;
18 import eu
.etaxonomy
.cdm
.api
.service
.config
.TaxonDeletionConfigurator
;
19 import eu
.etaxonomy
.cdm
.api
.service
.config
.TaxonNodeDeletionConfigurator
;
20 import eu
.etaxonomy
.cdm
.api
.service
.exception
.DataChangeNoRollbackException
;
21 import eu
.etaxonomy
.cdm
.model
.common
.ITreeNode
;
22 import eu
.etaxonomy
.cdm
.model
.reference
.Reference
;
23 import eu
.etaxonomy
.cdm
.model
.taxon
.ITaxonTreeNode
;
24 import eu
.etaxonomy
.cdm
.model
.taxon
.Synonym
;
25 import eu
.etaxonomy
.cdm
.model
.taxon
.SynonymRelationshipType
;
26 import eu
.etaxonomy
.cdm
.model
.taxon
.TaxonNode
;
31 * @created Apr 9, 2010
34 public interface ITaxonNodeService
extends IAnnotatableService
<TaxonNode
>{
40 @Deprecated // use findByUuid() instead; TODO will be removed in the next version
41 public TaxonNode
getTaxonNodeByUuid(UUID uuid
);
46 * @param propertyPaths
49 public List
<TaxonNode
> loadChildNodesOfTaxonNode(TaxonNode taxonNode
, List
<String
> propertyPaths
);
52 * Changes the taxon associated with the given taxon node into a synonym of the new accepted taxon node.
53 * All data associated with the former taxon are moved to the newly accepted taxon.
56 * @param newAcceptedTaxonNode
57 * @param synonymRelationshipType
59 * @param citationMicroReference
61 * @throws DataChangeNoRollbackException
63 public Synonym
makeTaxonNodeASynonymOfAnotherTaxonNode(TaxonNode oldTaxonNode
, TaxonNode newAcceptedTaxonNode
, SynonymRelationshipType synonymRelationshipType
, Reference citation
, String citationMicroReference
) throws DataChangeNoRollbackException
;
66 * deletes the given taxon nodes
73 List
<UUID
> deleteTaxonNodes(Set
<ITaxonTreeNode
> nodes
,
74 TaxonDeletionConfigurator config
) throws DataChangeNoRollbackException
;
76 * deletes the given taxon node the configurator defines whether the children will be deleted too or not
83 public UUID
deleteTaxonNode(TaxonNode node
, TaxonDeletionConfigurator config
)
84 throws DataChangeNoRollbackException
;