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 KetunaanKelainan
 * 
 * @author Generator
 */
@Entity // @Audited
@Table(name = "KetunaanKelainan_M")
public class KetunaanKelainan extends BaseMaster {
	@NotNull(message = "Kd Ketunaan Kelainan tidak boleh kosong")
	@Column(name = "KdKetunaanKelainan", nullable = false, length = 5)
	@Caption(value = "Kode Ketunaan Kelainan")
	private String kdKetunaanKelainan;

	public void setKdKetunaanKelainan(String kdKetunaanKelainan) {
		this.kdKetunaanKelainan = kdKetunaanKelainan;
	}

	public String getKdKetunaanKelainan() {
		return this.kdKetunaanKelainan;
	}

	@Column(name = "KetunaanKelainan", nullable = true, length = 150)
	@Caption(value = "Ketunaan Kelainan")
	private String ketunaanKelainan;

	public void setKetunaanKelainan(String ketunaanKelainan) {
		this.ketunaanKelainan = ketunaanKelainan;
	}

	public String getKetunaanKelainan() {
		return this.ketunaanKelainan;
	}

	@NotNull(message = "QKetunaan Kelainan tidak boleh kosong")
	@Column(name = "QKetunaanKelainan", nullable = false)
	@Caption(value = "QKetunaan Kelainan")
	private short qKetunaanKelainan;

	public void setqKetunaanKelainan(short qKetunaanKelainan) {
		this.qKetunaanKelainan = qKetunaanKelainan;
	}

	public short getqKetunaanKelainan() {
		return this.qKetunaanKelainan;
	}

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

	public Integer getId() {

		return id;
	}

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