1
|
/**
|
2
|
* Copyright (C) 2020 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.dto;
|
10
|
|
11
|
import java.util.UUID;
|
12
|
|
13
|
import eu.etaxonomy.cdm.model.name.Rank;
|
14
|
|
15
|
/**
|
16
|
* @author a.kohlbecker
|
17
|
* @since Mar 20, 2020
|
18
|
*/
|
19
|
public class SortableTaxonNodeQueryResult {
|
20
|
|
21
|
protected UUID taxonNodeUuid;
|
22
|
protected Integer taxonNodeId;
|
23
|
protected String treeIndex;
|
24
|
protected UUID taxonUuid;
|
25
|
protected String taxonTitleCache;
|
26
|
protected String nameTitleCache;
|
27
|
protected Rank nameRank = Rank.UNKNOWN_RANK();
|
28
|
protected UUID parentNodeUuid;
|
29
|
|
30
|
/**Is this the reason
|
31
|
* @param taxonNodeUuid
|
32
|
* @param taxonNodeId
|
33
|
* @param taxonTitleCache
|
34
|
* @param nameRank {@link Rank.#UNKNOWN_RANK()} will be used in case this is <code>null</code>
|
35
|
*/
|
36
|
public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, String treeIndex, UUID taxonUuid, String taxonTitleCache, String nameTitleCache,
|
37
|
Rank nameRank, UUID parentNodeUuid) {
|
38
|
this.taxonNodeUuid = taxonNodeUuid;
|
39
|
this.taxonNodeId = taxonNodeId;
|
40
|
this.treeIndex = treeIndex;
|
41
|
this.taxonUuid = taxonUuid;
|
42
|
this.taxonTitleCache = taxonTitleCache;
|
43
|
this.nameTitleCache = nameTitleCache;
|
44
|
if(nameRank != null){
|
45
|
this.nameRank = nameRank;
|
46
|
}
|
47
|
this.parentNodeUuid = parentNodeUuid;
|
48
|
}
|
49
|
|
50
|
/**
|
51
|
* @param taxonNodeUuid
|
52
|
* @param taxonNodeId
|
53
|
* @param taxonTitleCache
|
54
|
* @param nameRank {@link Rank.#UNKNOWN_RANK()} will be used in case this is <code>null</code>
|
55
|
*/
|
56
|
public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, String treeIndex, UUID taxonUuid, String taxonTitleCache,
|
57
|
Rank nameRank, UUID parentNodeUuid) {
|
58
|
this(taxonNodeUuid, taxonNodeId, treeIndex, taxonUuid, taxonTitleCache, null, nameRank, parentNodeUuid);
|
59
|
}
|
60
|
|
61
|
|
62
|
public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, String treeIndex, UUID taxonUuid, String taxonTitleCache,
|
63
|
Rank nameRank) {
|
64
|
this(taxonNodeUuid, taxonNodeId, treeIndex, taxonUuid, taxonTitleCache, null, nameRank, null);
|
65
|
}
|
66
|
|
67
|
public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, String taxonTitleCache,
|
68
|
Rank nameRank) {
|
69
|
this(taxonNodeUuid, taxonNodeId, null, null, taxonTitleCache, null, nameRank, null);
|
70
|
}
|
71
|
public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, UUID taxonUuid, String taxonTitleCache, UUID parentNodeUuid) {
|
72
|
this(taxonNodeUuid, taxonNodeId, null, taxonUuid, taxonTitleCache, null, parentNodeUuid);
|
73
|
}
|
74
|
public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, String taxonTitleCache, UUID parentNodeUuid) {
|
75
|
this(taxonNodeUuid, taxonNodeId, null, null, taxonTitleCache, null, parentNodeUuid);
|
76
|
}
|
77
|
|
78
|
public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, UUID taxonUuid, String taxonTitleCache) {
|
79
|
this(taxonNodeUuid, taxonNodeId, null, taxonUuid, taxonTitleCache, null, null);
|
80
|
}
|
81
|
public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, String taxonTitleCache) {
|
82
|
this(taxonNodeUuid, taxonNodeId, null, null, taxonTitleCache, null, null);
|
83
|
}
|
84
|
|
85
|
public UUID getTaxonNodeUuid() {
|
86
|
return taxonNodeUuid;
|
87
|
}
|
88
|
public void setTaxonNodeUuid(UUID taxonNodeUuid) {
|
89
|
this.taxonNodeUuid = taxonNodeUuid;
|
90
|
}
|
91
|
|
92
|
public String getTreeIndex() {
|
93
|
return treeIndex;
|
94
|
}
|
95
|
public void setTreeIndex(String treeIndex) {
|
96
|
this.treeIndex = treeIndex;
|
97
|
}
|
98
|
public UUID getTaxonUuid() {
|
99
|
return taxonUuid;
|
100
|
}
|
101
|
public void setTaxonUuid(UUID taxonUuid) {
|
102
|
this.taxonUuid = taxonUuid;
|
103
|
}
|
104
|
|
105
|
/**
|
106
|
* @return the parentNodeUuid
|
107
|
*/
|
108
|
public UUID getParentNodeUuid() {
|
109
|
return parentNodeUuid;
|
110
|
}
|
111
|
|
112
|
/**
|
113
|
* @param parentNodeUuid the parentNodeUuid to set
|
114
|
*/
|
115
|
public void setParentNodeUuid(UUID parentNodeUuid) {
|
116
|
this.parentNodeUuid = parentNodeUuid;
|
117
|
}
|
118
|
|
119
|
public Integer getTaxonNodeId() {
|
120
|
return taxonNodeId;
|
121
|
}
|
122
|
public void setTaxonNodeId(Integer taxonNodeId) {
|
123
|
this.taxonNodeId = taxonNodeId;
|
124
|
}
|
125
|
public String getTaxonTitleCache() {
|
126
|
return taxonTitleCache;
|
127
|
}
|
128
|
public void setTaxonTitleCache(String taxonTitleCache) {
|
129
|
this.taxonTitleCache = taxonTitleCache;
|
130
|
}
|
131
|
public Rank getNameRank() {
|
132
|
return nameRank;
|
133
|
}
|
134
|
public void setNameRank(Rank nameRank) {
|
135
|
this.nameRank = nameRank;
|
136
|
}
|
137
|
|
138
|
public String getNameTitleCache() {
|
139
|
return nameTitleCache;
|
140
|
}
|
141
|
public void setNameTitleCache(String nameTitleCache) {
|
142
|
this.nameTitleCache = nameTitleCache;
|
143
|
}
|
144
|
|
145
|
|
146
|
}
|