View Javadoc

1   /**
2    * Copyright 2011 The Kuali Foundation Licensed under the
3    * Educational Community License, Version 2.0 (the "License"); you may
4    * not use this file except in compliance with the License. You may
5    * obtain a copy of the License at
6    *
7    * http://www.osedu.org/licenses/ECL-2.0
8    *
9    * Unless required by applicable law or agreed to in writing,
10   * software distributed under the License is distributed on an "AS IS"
11   * BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
12   * or implied. See the License for the specific language governing
13   * permissions and limitations under the License.
14   */
15  
16  package org.kuali.mobility.notification.entity;
17  
18  import java.io.Serializable;
19  import java.util.Date;
20  
21  import javax.persistence.Column;
22  import javax.persistence.Entity;
23  import javax.persistence.GeneratedValue;
24  import javax.persistence.GenerationType;
25  import javax.persistence.Id;
26  import javax.persistence.Table;
27  import javax.persistence.Temporal;
28  import javax.persistence.TemporalType;
29  import javax.persistence.Version;
30  
31  @Entity
32  @Table(name="KME_NTFY_T")
33  public class Notification implements Serializable {
34  
35  	private static final long serialVersionUID = -95981285235712123L;
36  
37      @Id
38  	@GeneratedValue(strategy = GenerationType.TABLE)
39      @Column(name="ID")
40      private Long notificationId;
41  
42      @Temporal(TemporalType.TIMESTAMP)
43      @Column(name="STRT_DT")
44  	private Date startDate;
45  
46      @Temporal(TemporalType.TIMESTAMP)
47      @Column(name="END_DT")
48  	private Date endDate;
49  
50      @Column(name="TTL")
51  	private String title;
52  
53      @Column(name="MSG")
54      private String message;
55  
56      // TODO: This needs to be refactored to be a set of generic user attributes, permissions, etc
57      @Column(name="PRI_CMPS")
58      private String primaryCampus;
59  
60      @Column(name="TYP")
61      private Long notificationType;
62  
63      @Version
64      @Column(name="VER_NBR")
65      protected Long versionNumber;	
66  
67      public Long getNotificationId() {
68  		return notificationId;
69  	}
70  
71  	public void setNotificationId(Long notificationId) {
72  		this.notificationId = notificationId;
73  	}
74  
75  	public Date getStartDate() {
76  		return startDate;
77  	}
78  
79  	public void setStartDate(Date startDate) {
80  		this.startDate = startDate;
81  	}
82  
83  	public Date getEndDate() {
84  		return endDate;
85  	}
86  
87  	public void setEndDate(Date endDate) {
88  		this.endDate = endDate;
89  	}
90  
91  	public String getTitle() {
92  		return title;
93  	}
94  
95  	public void setTitle(String title) {
96  		this.title = title;
97  	}
98  
99  	public String getMessage() {
100 		return message;
101 	}
102 
103 	public void setMessage(String message) {
104 		this.message = message;
105 	}
106 
107 	public String getPrimaryCampus() {
108 		return primaryCampus;
109 	}
110 
111 	public void setPrimaryCampus(String primaryCampus) {
112 		this.primaryCampus = primaryCampus;
113 	}
114 
115 	public Long getNotificationType() {
116 		return notificationType;
117 	}
118 
119 	public void setNotificationType(Long notificationType) {
120 		this.notificationType = notificationType;
121 	}
122 
123 	public Long getVersionNumber() {
124 		return versionNumber;
125 	}
126 
127 	public void setVersionNumber(Long versionNumber) {
128 		this.versionNumber = versionNumber;
129 	}
130 	
131 }