package edu.mssm.pharm.maayanlab.Enrichr;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

@Entity
@DynamicInsert
@DynamicUpdate
@Table(name = "shared_genes", catalog = "enrichr")
public class SharedGene implements Serializable {

	private static final long serialVersionUID = -738468100827509312L;
	
	private Integer geneid;
	private SharedList sharedList;
	private String genename;

	public SharedGene() {
	}

	public SharedGene(SharedList sharedList, String genename) {
		this.sharedList = sharedList;
		this.genename = genename;
	}

	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "geneid", unique = true, nullable = false)
	public Integer getGeneid() {
		return this.geneid;
	}

	public void setGeneid(Integer geneid) {
		this.geneid = geneid;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "listid", nullable = false)
	public SharedList getSharedList() {
		return this.sharedList;
	}

	public void setSharedList(SharedList sharedList) {
		this.sharedList = sharedList;
	}

	@Column(name = "genename", nullable = false, length = 20)
	public String getGenename() {
		return this.genename;
	}

	public void setGenename(String genename) {
		this.genename = genename;
	}
}

@@ -1,8 +1,129 @@
+/**%0D%0A * Model for storing genes from crowdsourced lists%0D%0A * %0D%0A * @author%09%09Edward Y. Chen%0D%0A * @since%09%0904/17/2013 %0D%0A */%0D%0A%0D%0A
 package 

Add comments