package com.siemens.nkg.ejb.domain;

import java.io.Serializable;
import java.math.BigDecimal;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.persistence.UniqueConstraint;

@Entity
@Table(name = "DPC_POSTCODE", schema = "MCS", uniqueConstraints = @UniqueConstraint(columnNames = "DPC_POSTCODE"))
@NamedQueries(value = { @NamedQuery(name = "findPostcodes", query = "SELECT POST.dpcPostcode FROM DpcPostcode AS POST ORDER BY POST.dpcPostcode") })
public class DpcPostcode implements Serializable {
  private static final long serialVersionUID = -4204990583464868822L;
  private String dpcPostcode;
  private String dpcCchChute1;
  private String dpcCchChute2;
  private BigDecimal dpcCreatetime;
  private BigDecimal dpcModtime;

  public DpcPostcode() {

  }

  public DpcPostcode(String dpcPostcode, String dpcCchChute1, String dpcCchChute2, BigDecimal dpcCreatetime) {
    this.dpcPostcode = dpcPostcode;
    this.dpcCchChute1 = dpcCchChute1;
    this.dpcCchChute2 = dpcCchChute2;
    this.dpcCreatetime = dpcCreatetime;
  }

  public DpcPostcode(String dpcPostcode, String dpcCchChute1, String dpcCchChute2, BigDecimal dpcCreatetime,
      BigDecimal dpcModtime) {
    this.dpcPostcode = dpcPostcode;
    this.dpcCchChute1 = dpcCchChute1;
    this.dpcCchChute2 = dpcCchChute2;
    this.dpcCreatetime = dpcCreatetime;
    this.dpcModtime = dpcModtime;
  }

  @Id
  @Column(name = "DPC_POSTCODE", unique = true, nullable = false, length = 6)
  public String getDpcPostcode() {
    return this.dpcPostcode;
  }

  public void setDpcPostcode(String dpcPostcode) {
    this.dpcPostcode = dpcPostcode;
  }

  @Column(name = "DPC_CCH_CHUTE1", nullable = false, length = 12)
  public String getDpcCchChute1() {
    return this.dpcCchChute1;
  }

  public void setDpcCchChute1(String dpcCchChute1) {
    this.dpcCchChute1 = dpcCchChute1;
  }

  @Column(name = "DPC_CCH_CHUTE2", length = 12)
  public String getDpcCchChute2() {
    return this.dpcCchChute2;
  }

  public void setDpcCchChute2(String dpcCchChute2) {
    this.dpcCchChute2 = dpcCchChute2;
  }

  @Column(name = "DPC_CREATETIME", nullable = false, precision = 13, scale = 3)
  public BigDecimal getDpcCreatetime() {
    return this.dpcCreatetime;
  }

  public void setDpcCreatetime(BigDecimal dpcCreatetime) {
    this.dpcCreatetime = dpcCreatetime;
  }

  @Column(name = "DPC_MODTIME", precision = 13, scale = 3)
  public BigDecimal getDpcModtime() {
    return this.dpcModtime;
  }

  public void setDpcModtime(BigDecimal dpcModtime) {
    this.dpcModtime = dpcModtime;
  }

}
