package com.jasamedika.medifirst2000.entities;

import java.io.Serializable;
import org.hibernate.envers.Audited;
import javax.persistence.*;

import org.hibernate.validator.constraints.NotEmpty;

import com.jasamedika.medifirst2000.base.BaseMaster;
import javax.validation.constraints.NotNull;
import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.internal.util.logging.Messages;

import com.fasterxml.jackson.annotation.JsonManagedReference;
import com.jasamedika.medifirst2000.base.BaseMaster;
import com.jasamedika.medifirst2000.helper.Caption;
import org.hibernate.envers.Audited;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;

/**
 * class MapTindakanMedisToKualitasHasil
 * 
 * @author Generator
 */
@Entity // @Audited
@Table(name = "MapTindakanMedisToKualitasHasil_M")
public class MapTindakanMedisToKualitasHasil extends BaseMaster {
	@ManyToOne
	@JoinColumn(name = "ObjectKualitasHasilFk")
	@NotNull(message = "Kd Kualitas Hasil tidak boleh kosong")

	@Caption(value = "Object Kualitas Hasil")
	private KualitasHasil kualitasHasil;

	public void setKualitasHasil(KualitasHasil kualitasHasil) {
		this.kualitasHasil = kualitasHasil;
	}

	public KualitasHasil getKualitasHasil() {
		return this.kualitasHasil;
	}

	@Column(name = "ObjectKualitasHasilFk", insertable = false, updatable = false)
	private Integer kualitasHasilId;

	@ManyToOne
	@JoinColumn(name = "ObjectTindakanMedisFk")
	@NotNull(message = "Kd Tindakan Medis tidak boleh kosong")

	@Caption(value = "Object Tindakan Medis")
	private TindakanMedis tindakanMedis;

	public void setindakanMedis(TindakanMedis tindakanMedis) {
		this.tindakanMedis = tindakanMedis;
	}

	public TindakanMedis getTindakanMedis() {
		return this.tindakanMedis;
	}

	@Column(name = "ObjectTindakanMedisFk", insertable = false, updatable = false, nullable = false)
	private Integer tindakanMedisId;

	@Id
	@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "public.maptindakanmedistokualitashasil_m_id_seq")
	@javax.persistence.SequenceGenerator(name = "public.maptindakanmedistokualitashasil_m_id_seq", sequenceName = "public.maptindakanmedistokualitashasil_m_id_seq", allocationSize = 1)
	@Column(name = "id")
	protected Integer id;

	public Integer getId() {

		return id;
	}

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