package com.jasamedika.medifirst2000.entities;

import java.io.Serializable;
import org.hibernate.envers.Audited;
import java.util.Date;
import java.util.HashSet;
import java.util.Set;

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 Produk
 * 
 * @author Generator
 */
@Entity // @Audited
@Table(name = "ProdukDetailLaboratoriumNilaiNormal_M")
public class ProdukDetailLaboratoriumNilaiNormal extends BaseMaster {

	@Caption(value = "Umur Minimal")
	@Column(name = "ageMin", nullable = true, length = 300)
	private Double ageMin;

	@Caption(value = "Umur Maximal")
	@Column(name = "ageMax", nullable = true, length = 300)
	private Double ageMax;

	@Caption(value = "Detail Pemeriksaan")
	@Column(name = "ageUnit", nullable = true, length = 5)
	private String ageUnit;

	@Caption(value = "Detail Pemeriksaan")
	@Column(name = "panicRange", nullable = true, length = 3)
	private String panicRange;

	public Double getAgeMin() {
		return ageMin;
	}

	public void setAgeMin(Double ageMin) {
		this.ageMin = ageMin;
	}

	public Double getAgeMax() {
		return ageMax;
	}

	public void setAgeMax(Double ageMax) {
		this.ageMax = ageMax;
	}

	public String getAgeUnit() {
		return ageUnit;
	}

	public void setAgeUnit(String ageUnit) {
		this.ageUnit = ageUnit;
	}

	public String getPanicRange() {
		return panicRange;
	}

	public void setPanicRange(String panicRange) {
		this.panicRange = panicRange;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "ObjectJenisKelaminFK")
	@Caption(value = "Jenis Kelamin")
	private JenisKelamin jenisKelamin;

	@Column(name = "ObjectJenisKelaminFK", insertable = false, updatable = false)
	private Integer jenisKelaminFk;
	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "ObjectProdukDetailLabFK")
	@Caption(value = "Produk")
	private ProdukDetailLaboratorium produkDetailLaboratorium;

	public JenisKelamin getJenisKelamin() {
		return jenisKelamin;
	}

	public void setJenisKelamin(JenisKelamin jenisKelamin) {
		this.jenisKelamin = jenisKelamin;
	}

	public ProdukDetailLaboratorium getProdukDetailLaboratorium() {
		return produkDetailLaboratorium;
	}

	public void setProdukDetailLaboratorium(ProdukDetailLaboratorium produkDetailLaboratorium) {
		this.produkDetailLaboratorium = produkDetailLaboratorium;
	}

	public double getRangeMin() {
		return rangeMin;
	}

	public void setRangeMin(double rangeMin) {
		this.rangeMin = rangeMin;
	}

	public double getRangeMax() {
		return rangeMax;
	}

	public void setRangeMax(double rangeMax) {
		this.rangeMax = rangeMax;
	}

	@Column(name = "ObjectProdukDetailLabFK", insertable = false, updatable = false)
	private Integer produkFk;

	@Caption(value = "Range Min")
	@Column(name = "RangeMin", nullable = false)
	private double rangeMin;
	@Caption(value = "Range Max")
	@Column(name = "RangeMax", nullable = false)
	private double rangeMax;

	@Caption(value = "RefRange")
	@Column(name = "RefRange", nullable = true)
	private String refRange;

	@Caption(value = "Tipe Data Hasil")
	@Column(name = "TipeDataHasil", nullable = true)
	private String tipeDataHasil;

	public String getRefRange() {
		return refRange;
	}

	public void setRefRange(String refRange) {
		this.refRange = refRange;
	}

	public String getTipeDataHasil() {
		return tipeDataHasil;
	}

	public void setTipeDataHasil(String tipeDataHasil) {
		this.tipeDataHasil = tipeDataHasil;
	}

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

	public Integer getId() {

		return id;
	}

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