summaryrefslogtreecommitdiffstats
path: root/proxy/code/src
diff options
context:
space:
mode:
authorDevan Goodwin <dgoodwin@redhat.com>2009-11-06 12:50:04 -0400
committerDevan Goodwin <dgoodwin@redhat.com>2009-11-06 12:50:04 -0400
commit8d167b75c4cc028dedd5d99f94cdf8f27bb25c16 (patch)
tree7c6bb11ee7e59ac23c2daaf962dfc003b96d6bf5 /proxy/code/src
parent54d01e4b118d8d123d675caecdfdfc0b6414a0e2 (diff)
downloadcandlepin-8d167b75c4cc028dedd5d99f94cdf8f27bb25c16.tar.gz
candlepin-8d167b75c4cc028dedd5d99f94cdf8f27bb25c16.tar.xz
candlepin-8d167b75c4cc028dedd5d99f94cdf8f27bb25c16.zip
Complete ConsumerType db mapping.
Diffstat (limited to 'proxy/code/src')
-rw-r--r--proxy/code/src/org/fedoraproject/candlepin/model/ConsumerType.java27
1 files changed, 25 insertions, 2 deletions
diff --git a/proxy/code/src/org/fedoraproject/candlepin/model/ConsumerType.java b/proxy/code/src/org/fedoraproject/candlepin/model/ConsumerType.java
index 9ead523..b5bb510 100644
--- a/proxy/code/src/org/fedoraproject/candlepin/model/ConsumerType.java
+++ b/proxy/code/src/org/fedoraproject/candlepin/model/ConsumerType.java
@@ -14,20 +14,27 @@
*/
package org.fedoraproject.candlepin.model;
+import java.io.Serializable;
+
import javax.persistence.Entity;
+import javax.persistence.GeneratedValue;
+import javax.persistence.GenerationType;
import javax.persistence.Id;
+import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlRootElement;
/**
- * Represents the tyep of consumer.
+ * Represents the type of consumer.
*/
@XmlRootElement
@XmlAccessorType(XmlAccessType.PROPERTY)
@Entity
-public class ConsumerType extends BaseModel {
+@Table(name="cp_consumer_type")
+public class ConsumerType extends BaseModel implements Serializable {
+ private Long id;
private String label;
/**
@@ -47,6 +54,22 @@ public class ConsumerType extends BaseModel {
}
/**
+ * @return the id
+ */
+ @Id
+ @GeneratedValue(strategy=GenerationType.AUTO)
+ public Long getId() {
+ return id;
+ }
+
+ /**
+ * @param id the id to set
+ */
+ public void setId(Long id) {
+ this.id = id;
+ }
+
+ /**
* @return Returns the label.
*/
@Id