added isKindOf and getGeneralisationOf(recursive) to IEnumTerm #3611
[cdmlib.git] / cdmlib-model / src / main / java / eu / etaxonomy / cdm / model / common / ISimpleTerm.java
1 /**
2 *
3 */
4 package eu.etaxonomy.cdm.model.common;
5
6 import java.util.Set;
7 import java.util.UUID;
8
9 import javax.persistence.Transient;
10
11 /**
12 * The common interface which is implemented by {@link DefinedTermBase defined terms} and enumerations
13 * replacing fully {@link DefinedTermBase defined terms}.
14 *
15 * @author a.mueller
16 * @created 14-Jul-1913
17 */
18 public interface ISimpleTerm<T extends ISimpleTerm> {
19
20 @Transient
21 public UUID getUuid();
22
23 //is static !!
24 // public T getByUuid(UUID uuid);
25
26
27 /**
28 * Returns the defined term this term is a kind of.
29 * Therefore the returned term is a generalization of <code>this</code> term
30 */
31 public T getKindOf();
32
33
34 /**
35 * Returns all defined terms this term is a direct generalization for.
36 * Therefore the returned terms are kind of <code>this</code> term.
37 */
38 public Set<T> getGeneralizationOf();
39
40 }