(no commit message)
[cdmlib.git] / cdmlib-model / src / main / java / eu / etaxonomy / cdm / model / name / HybridRelationshipType.java
1 /**
2 * Copyright (C) 2007 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
10 package eu.etaxonomy.cdm.model.name;
11
12 import java.util.UUID;
13
14 import eu.etaxonomy.cdm.model.common.RelationshipTermBase;
15 import org.apache.log4j.Logger;
16 import javax.persistence.*;
17
18 /**
19 * The list should be extensible at runtime through configuration. This needs to
20 * be investigated.
21 * @author m.doering
22 * @version 1.0
23 * @created 08-Nov-2007 13:06:27
24 */
25 @Entity
26 public class HybridRelationshipType extends RelationshipTermBase<HybridRelationshipType> {
27 static Logger logger = Logger.getLogger(HybridRelationshipType.class);
28
29 private static final UUID uuidFirstParent = UUID.fromString("83ae9e56-18f2-46b6-b211-45cdee775bf3");
30 private static final UUID uuidSecondParent = UUID.fromString("0485fc3d-4755-4f53-8832-b82774484c43");
31 private static final UUID uuidFemaleParent = UUID.fromString("189a3ed9-6860-4943-8be8-a1f60133be2a");
32 private static final UUID uuidMaleParent = UUID.fromString("8b7324c5-cc6c-4109-b708-d49b187815c4");
33
34
35 public HybridRelationshipType() {
36 super();
37 }
38 public HybridRelationshipType(String term, String label, boolean symmetric, boolean transitive) {
39 super(term, label, symmetric, transitive);
40 // TODO Auto-generated constructor stub
41 }
42
43
44 public static final HybridRelationshipType getbyUuid(UUID uuid){
45 return (HybridRelationshipType) findByUuid(uuid);
46 }
47
48 public static final HybridRelationshipType FIRST_PARENT(){
49 return getbyUuid(uuidFirstParent);
50 }
51
52 public static final HybridRelationshipType SECOND_PARENT(){
53 return getbyUuid(uuidSecondParent);
54 }
55
56 public static final HybridRelationshipType FEMALE_PARENT(){
57 return getbyUuid(uuidFemaleParent);
58 }
59
60 public static final HybridRelationshipType MALE_PARENT(){
61 return getbyUuid(uuidMaleParent);
62 }
63
64 }