Project

General

Profile

Download (3.59 KB) Statistics
| Branch: | Tag: | Revision:
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 taxonTitleCache;
24
    protected String nameTitleCache;
25
    protected Rank nameRank = Rank.UNKNOWN_RANK();
26
    protected UUID parentNodeUuid;
27

    
28
    /**Is this the reason
29
     * @param taxonNodeUuid
30
     * @param taxonNodeId
31
     * @param taxonTitleCache
32
     * @param nameRank {@link Rank.#UNKNOWN_RANK()} will be used in case this is <code>null</code>
33
     */
34
    public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, String taxonTitleCache, String nameTitleCache,
35
            Rank nameRank, UUID parentNodeUuid) {
36
        this.taxonNodeUuid = taxonNodeUuid;
37
        this.taxonNodeId = taxonNodeId;
38
        this.taxonTitleCache = taxonTitleCache;
39
        this.nameTitleCache = nameTitleCache;
40
        if(nameRank != null){
41
            this.nameRank = nameRank;
42
        }
43
        this.parentNodeUuid = parentNodeUuid;
44
    }
45

    
46
    /**
47
     * @param taxonNodeUuid
48
     * @param taxonNodeId
49
     * @param taxonTitleCache
50
     * @param nameRank {@link Rank.#UNKNOWN_RANK()} will be used in case this is <code>null</code>
51
     */
52
    public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, String taxonTitleCache,
53
            Rank nameRank, UUID parentNodeUuid) {
54
        this(taxonNodeUuid, taxonNodeId, taxonTitleCache, null, nameRank, parentNodeUuid);
55
    }
56

    
57

    
58
    public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, String taxonTitleCache,
59
            Rank nameRank) {
60
        this(taxonNodeUuid, taxonNodeId, taxonTitleCache, null, nameRank, null);
61
    }
62
    public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, String taxonTitleCache, UUID parentNodeUuid) {
63
        this(taxonNodeUuid, taxonNodeId, taxonTitleCache, null, parentNodeUuid);
64
    }
65
    public SortableTaxonNodeQueryResult(UUID taxonNodeUuid, Integer taxonNodeId, String taxonTitleCache) {
66
        this(taxonNodeUuid, taxonNodeId, taxonTitleCache, null, null);
67
    }
68

    
69
    public UUID getTaxonNodeUuid() {
70
        return taxonNodeUuid;
71
    }
72
    public void setTaxonNodeUuid(UUID taxonNodeUuid) {
73
        this.taxonNodeUuid = taxonNodeUuid;
74
    }
75
    /**
76
     * @return the parentNodeUuid
77
     */
78
    public UUID getParentNodeUuid() {
79
        return parentNodeUuid;
80
    }
81

    
82
    /**
83
     * @param parentNodeUuid the parentNodeUuid to set
84
     */
85
    public void setParentNodeUuid(UUID parentNodeUuid) {
86
        this.parentNodeUuid = parentNodeUuid;
87
    }
88

    
89
    public Integer getTaxonNodeId() {
90
        return taxonNodeId;
91
    }
92
    public void setTaxonNodeId(Integer taxonNodeId) {
93
        this.taxonNodeId = taxonNodeId;
94
    }
95
    public String getTaxonTitleCache() {
96
        return taxonTitleCache;
97
    }
98
    public void setTaxonTitleCache(String taxonTitleCache) {
99
        this.taxonTitleCache = taxonTitleCache;
100
    }
101
    public Rank getNameRank() {
102
        return nameRank;
103
    }
104
    public void setNameRank(Rank nameRank) {
105
        this.nameRank = nameRank;
106
    }
107

    
108
    public String getNameTitleCache() {
109
        return nameTitleCache;
110
    }
111
    public void setNameTitleCache(String nameTitleCache) {
112
        this.nameTitleCache = nameTitleCache;
113
    }
114

    
115

    
116
}
(14-14/30)