package com.jasamedika.medifirst2000.entities;

import java.util.HashSet;
import java.util.Set;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;

import com.fasterxml.jackson.annotation.JsonBackReference;
import com.jasamedika.medifirst2000.base.BaseMaster;
import com.jasamedika.medifirst2000.helper.Caption;

/**
 *  class KelompokShift
 * 
 * @author Generator
 */
@Entity
@Table(name = "sdm_KelompokShift_M")
public class KelompokShift  extends BaseMaster{
	
	@Id
	@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "public.sdm_KelompokShift_T")
	@javax.persistence.SequenceGenerator(name = "public.sdm_KelompokShift_T", sequenceName = "public.sdm_KelompokShift_T", allocationSize = 1)
	@Column(name = "id")
	protected Integer id;
	
	@JsonBackReference
	@OneToMany(cascade=CascadeType.ALL,fetch = FetchType.EAGER, mappedBy = "kelompokShift")
	private Set<ShiftKerja> detail=new HashSet<ShiftKerja>();

	@Column(name = "Kode", nullable = false , length = 100)
	@Caption(value = "Kode")
	private Integer kode ;

	@Column(name = "Name", nullable = false , length = 100)
	@Caption(value = "Name")
	private String name ;
	
	@Column(name="KdKelompokShiftKerja")
	@Caption(value="Kd Kelompok Shift Kerja")
	private Integer kdKelompokShiftKerja;
	
	@Column(name="KelompokShiftKerja", length=30)
	@Caption(value="Kelompok Shift Kerja")
	private String kelompokShiftKerja;
	
	@Column(name="FactorRate")
	@Caption(value="Factor Rate")
	private Integer factorRate;
	
	@Column(name="OperatorFactorRate")
	@Caption(value="Operator Factor Rate")
	private String operatorFactorRate;
	
	@Column(name="QKelompokShift")
	@Caption(value="Q Kelompo kShift")
	private Integer qKelompokShift;

	public Integer getId() {
		return id;
	}

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

	public Set<ShiftKerja> getDetail() {
		return detail;
	}

	public void setDetail(Set<ShiftKerja> detail) {
		this.detail = detail;
	}

	public Integer getKode() {
		return kode;
	}

	public void setKode(Integer kode) {
		this.kode = kode;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Integer getKdKelompokShiftKerja() {
		return kdKelompokShiftKerja;
	}

	public void setKdKelompokShiftKerja(Integer kdKelompokShiftKerja) {
		this.kdKelompokShiftKerja = kdKelompokShiftKerja;
	}

	public String getKelompokShiftKerja() {
		return kelompokShiftKerja;
	}

	public void setKelompokShiftKerja(String kelompokShiftKerja) {
		this.kelompokShiftKerja = kelompokShiftKerja;
	}	

	public String getOperatorFactorRate() {
		return operatorFactorRate;
	}

	public void setOperatorFactorRate(String operatorFactorRate) {
		this.operatorFactorRate = operatorFactorRate;
	}

	public Integer getqKelompokShift() {
		return qKelompokShift;
	}

	public void setqKelompokShift(Integer qKelompokShift) {
		this.qKelompokShift = qKelompokShift;
	}
	
	
	
	

}