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.occurrence;
|
11
|
|
12
|
|
13
|
import org.apache.log4j.Logger;
|
14
|
import org.hibernate.annotations.Cascade;
|
15
|
import org.hibernate.annotations.CascadeType;
|
16
|
|
17
|
import javax.persistence.*;
|
18
|
|
19
|
/**
|
20
|
* In situ observation of a taxon in the field. If a specimen exists,
|
21
|
* in most cases a parallel field observation object should be instantiated and the specimen then is "derived" from the field unit
|
22
|
* @author m.doering
|
23
|
* @version 1.0
|
24
|
* @created 08-Nov-2007 13:06:40
|
25
|
*/
|
26
|
@Entity
|
27
|
public class FieldObservation extends SpecimenOrObservationBase{
|
28
|
private static final Logger logger = Logger.getLogger(FieldObservation.class);
|
29
|
|
30
|
private String fieldNumber;
|
31
|
private String fieldNotes;
|
32
|
private GatheringEvent gatheringEvent;
|
33
|
|
34
|
/**
|
35
|
* Factory method
|
36
|
* @return
|
37
|
*/
|
38
|
public static FieldObservation NewInstance(){
|
39
|
return new FieldObservation();
|
40
|
}
|
41
|
|
42
|
|
43
|
/**
|
44
|
* Constructor
|
45
|
*/
|
46
|
protected FieldObservation(){
|
47
|
super();
|
48
|
}
|
49
|
|
50
|
@Override
|
51
|
@ManyToOne
|
52
|
@Cascade( { CascadeType.SAVE_UPDATE })
|
53
|
public GatheringEvent getGatheringEvent() {
|
54
|
return this.gatheringEvent;
|
55
|
}
|
56
|
public void setGatheringEvent(GatheringEvent gatheringEvent) {
|
57
|
this.gatheringEvent = gatheringEvent;
|
58
|
}
|
59
|
|
60
|
|
61
|
public String getFieldNumber() {
|
62
|
return fieldNumber;
|
63
|
}
|
64
|
public void setFieldNumber(String fieldNumber) {
|
65
|
this.fieldNumber = fieldNumber;
|
66
|
}
|
67
|
|
68
|
|
69
|
public String getFieldNotes() {
|
70
|
return fieldNotes;
|
71
|
}
|
72
|
public void setFieldNotes(String fieldNotes) {
|
73
|
this.fieldNotes = fieldNotes;
|
74
|
}
|
75
|
|
76
|
}
|