1 /**
2 * Copyright 2011-2013 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.writer.entity;
17
18 import javax.persistence.*;
19
20 /**
21 * Class representing a topic for an article
22 * @author Kuali Mobility Team (mobility.dev@kuali.org)
23 * @since 3.0.0
24 */
25 @NamedQueries({
26 @NamedQuery(
27 name = "Topic.getTopics",
28 query = "SELECT t FROM Topic t")
29 })
30 @Entity
31 @Table(name="WRITER_ARTICLE_TOPIC")
32 public class Topic {
33
34
35
36 /** A id for the Topic */
37 @Id
38 // @GeneratedValue(strategy = GenerationType.IDENTITY)
39 @GeneratedValue(strategy = GenerationType.TABLE)
40 @Column(name="ID")
41 private long id;
42
43
44 /** The catelog label string */
45 @Column(name="LABEL")
46 private String label;
47
48 /**
49 * Description of the Topic
50 */
51 @Column(name="DESCRIPTION")
52 private String description;
53
54 /**
55 * @return the name
56 */
57 public String getLabel() {
58 return label;
59 }
60 /**
61 * @return the id
62 */
63 public long getId() {
64 return id;
65 }
66 /**
67 * @return the description
68 */
69 public String getDescription() {
70 return description;
71 }
72 /**
73 * @param description the description to set
74 */
75 public void setDescription(String description) {
76 this.description = description;
77 }
78 /**
79 * @param id the id to set
80 */
81 public void setId(long id) {
82 this.id = id;
83 }
84
85
86
87 }