package org.tnc.rbsf.jpa;

import java.io.Serializable;
import java.util.Date;
import java.util.Set;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.Lob;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;

@Entity
public class Report implements Serializable {
	@Id
	private String id;

	@Column(name="shared_on")
	private Date sharedOn;

	private double version;

	@Lob
	private String report;

	@Column(name="last_mod_od")
	private Date lastModOd;

	@ManyToOne
	@JoinColumn(name="project_Id")
	private Project projectId;

	@OneToMany(mappedBy="report")
	private Set<Comments> commentsCollection;

	@OneToMany(mappedBy="report")
	private Set<RepDownloads> repDownloadsCollection;

	private static final long serialVersionUID = 1L;

	public Report() {
		super();
	}

	public String getId() {
		return this.id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public Date getSharedOn() {
		return this.sharedOn;
	}

	public void setSharedOn(Date sharedOn) {
		this.sharedOn = sharedOn;
	}

	public double getVersion() {
		return this.version;
	}

	public void setVersion(double version) {
		this.version = version;
	}

	public String getReport() {
		return this.report;
	}

	public void setReport(String report) {
		this.report = report;
	}

	public Date getLastModOd() {
		return this.lastModOd;
	}

	public void setLastModOd(Date lastModOd) {
		this.lastModOd = lastModOd;
	}

	public Project getProjectId() {
		return this.projectId;
	}

	public void setProjectId(Project projectId) {
		this.projectId = projectId;
	}

	public Set<Comments> getCommentsCollection() {
		return this.commentsCollection;
	}

	public void setCommentsCollection(Set<Comments> commentsCollection) {
		this.commentsCollection = commentsCollection;
	}

	public Set<RepDownloads> getRepDownloadsCollection() {
		return this.repDownloadsCollection;
	}

	public void setRepDownloadsCollection(Set<RepDownloads> repDownloadsCollection) {
		this.repDownloadsCollection = repDownloadsCollection;
	}

}
