1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.ken.bo;
17
18 import org.hibernate.annotations.GenericGenerator;
19 import org.hibernate.annotations.Parameter;
20 import org.kuali.rice.krad.bo.PersistableBusinessObjectBase;
21
22 import javax.persistence.*;
23
24
25
26
27
28
29 @Entity
30 @Table(name="KREN_RECIP_T")
31 public class NotificationRecipient extends PersistableBusinessObjectBase{
32 @Id
33 @GeneratedValue(generator="KREN_RECIP_S")
34 @GenericGenerator(name="KREN_RECIP_S",strategy="org.hibernate.id.enhanced.SequenceStyleGenerator",parameters={
35 @Parameter(name="sequence_name",value="KREN_RECIP_S"),
36 @Parameter(name="value_column",value="id")
37 })
38 @Column(name="RECIP_ID")
39 private Long id;
40 @Column(name="NTFCTN_ID", nullable=false)
41 private Long notificationId;
42 @Column(name="RECIP_TYP_CD", nullable=false)
43 private String recipientType;
44 @Column(name="PRNCPL_ID", nullable=false)
45 private String recipientId;
46
47
48 @ManyToOne(fetch=FetchType.EAGER, cascade={CascadeType.PERSIST, CascadeType.REMOVE})
49 @JoinColumn(name="NTFCTN_ID", insertable=false, updatable=false)
50 private Notification notification;
51
52
53
54
55 public NotificationRecipient() {
56 }
57
58
59
60
61
62 public Long getId() {
63 return id;
64 }
65
66
67
68
69
70 public void setId(Long id) {
71 this.id = id;
72 }
73
74
75
76
77
78 public Long getNotificationId() {
79 return notificationId;
80 }
81
82
83
84
85
86 public void setNotificationId(Long notificationId) {
87 this.notificationId = notificationId;
88 }
89
90
91
92
93
94 public String getRecipientId() {
95 return recipientId;
96 }
97
98
99
100
101
102 public void setRecipientId(String recipientId) {
103 this.recipientId = recipientId;
104 }
105
106
107
108
109
110 public String getRecipientType() {
111 return recipientType;
112 }
113
114
115
116
117
118 public void setRecipientType(String recipientType) {
119 this.recipientType = recipientType;
120 }
121 }
122