1
|
/**
|
2
|
* Copyright (C) 2018 EDIT
|
3
|
* European Distributed Institute of Taxonomy
|
4
|
* http://www.e-taxonomy.eu
|
5
|
*
|
6
|
* The contents of this file are subject to the Mozilla Public License Version 1.1
|
7
|
* See LICENSE.TXT at the top of this package for the full license terms.
|
8
|
*/
|
9
|
package eu.etaxonomy.cdm.persistence.dao.taxonGraph;
|
10
|
|
11
|
import java.util.List;
|
12
|
import java.util.UUID;
|
13
|
|
14
|
import eu.etaxonomy.cdm.model.name.TaxonName;
|
15
|
import eu.etaxonomy.cdm.model.taxon.Taxon;
|
16
|
import eu.etaxonomy.cdm.model.taxon.TaxonRelationshipType;
|
17
|
import eu.etaxonomy.cdm.persistence.dto.TaxonGraphEdgeDTO;
|
18
|
|
19
|
/**
|
20
|
* @author a.kohlbecker
|
21
|
* @since Sep 26, 2018
|
22
|
*
|
23
|
*/
|
24
|
public interface ITaxonGraphDao {
|
25
|
|
26
|
/**
|
27
|
*
|
28
|
* @param fromTaxonUuid
|
29
|
* Can be <code>null</code> to retrieve all edges having the toName as target.
|
30
|
* @param toTaxonUuid
|
31
|
* Can be <code>null</code> to retrieve all edges originating from the fromName as target.
|
32
|
* @param type
|
33
|
* @param includeUnpublished
|
34
|
* @return
|
35
|
*/
|
36
|
public List<TaxonGraphEdgeDTO> listTaxonGraphEdgeDTOs(UUID fromTaxonUuid, UUID toTaxonUuid, TaxonRelationshipType type,
|
37
|
boolean includeUnpublished, Integer pageSize, Integer pageIndex);
|
38
|
|
39
|
/**
|
40
|
* @param fromTaxonUuid
|
41
|
* Can be <code>null</code> to retrieve all edges having the toName as target.
|
42
|
* @param toTaxonUuid
|
43
|
* Can be <code>null</code> to retrieve all edges originating from the fromName as target.
|
44
|
* @param type
|
45
|
* @param includeUnpublished
|
46
|
* @return
|
47
|
*/
|
48
|
public long countTaxonGraphEdgeDTOs(UUID fromTaxonUuid, UUID toTaxonUuid, TaxonRelationshipType type,
|
49
|
boolean includeUnpublished);
|
50
|
|
51
|
public List<TaxonGraphEdgeDTO> edges(UUID fromtaxonUuid, UUID toTaxonUuid, boolean includeUnpublished) throws TaxonGraphException;
|
52
|
|
53
|
public List<TaxonGraphEdgeDTO> edges(TaxonName fromName, TaxonName toName, boolean includeUnpublished) throws TaxonGraphException;
|
54
|
|
55
|
public Taxon assureSingleTaxon(TaxonName taxonName) throws TaxonGraphException;
|
56
|
|
57
|
public Taxon assureSingleTaxon(TaxonName taxonName, boolean createMissing) throws TaxonGraphException;
|
58
|
|
59
|
}
|