package com.ag.web.edi;

import java.io.Serializable;
import java.util.Collection;
import java.util.Date;

/**
 * 
 * @author Administrator
 */
public class EcError implements Serializable {
	private static final long serialVersionUID = 1L;
	private String errCod;
	private String errNam;
	private String errLev;
	private String description;
	private String insAccount;
	private Date insTimestamp;
	private String updAccount;
	private Date updTimestamp;
	private String tenantId;
	private ELogError logId;
	private Collection<ELogError> eLogErrorCollection;

	public EcError() {
	}

	public EcError(String errCod) {
		this.errCod = errCod;
	}

	public EcError(String errCod, String errNam, String errLev, String insAccount, Date insTimestamp, String tenantId) {
		this.errCod = errCod;
		this.errNam = errNam;
		this.errLev = errLev;
		this.insAccount = insAccount;
		this.insTimestamp = insTimestamp;
		this.tenantId = tenantId;
	}

	public String getErrCod() {
		return errCod;
	}

	public void setErrCod(String errCod) {
		this.errCod = errCod;
	}

	public String getErrNam() {
		return errNam;
	}

	public void setErrNam(String errNam) {
		this.errNam = errNam;
	}

	public String getErrLev() {
		return errLev;
	}

	public void setErrLev(String errLev) {
		this.errLev = errLev;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public String getInsAccount() {
		return insAccount;
	}

	public void setInsAccount(String insAccount) {
		this.insAccount = insAccount;
	}

	public Date getInsTimestamp() {
		return insTimestamp;
	}

	public void setInsTimestamp(Date insTimestamp) {
		this.insTimestamp = insTimestamp;
	}

	public String getUpdAccount() {
		return updAccount;
	}

	public void setUpdAccount(String updAccount) {
		this.updAccount = updAccount;
	}

	public Date getUpdTimestamp() {
		return updTimestamp;
	}

	public void setUpdTimestamp(Date updTimestamp) {
		this.updTimestamp = updTimestamp;
	}

	public String getTenantId() {
		return tenantId;
	}

	public void setTenantId(String tenantId) {
		this.tenantId = tenantId;
	}

	public ELogError getLogId() {
		return logId;
	}

	public void setLogId(ELogError logId) {
		this.logId = logId;
	}

	public Collection<ELogError> getELogErrorCollection() {
		return eLogErrorCollection;
	}

	public void setELogErrorCollection(Collection<ELogError> eLogErrorCollection) {
		this.eLogErrorCollection = eLogErrorCollection;
	}

	@Override
	public int hashCode() {
		int hash = 0;
		hash += (errCod != null ? errCod.hashCode() : 0);
		return hash;
	}

	@Override
	public boolean equals(Object object) {
		// TODO: Warning - this method won't work in the case the id fields are
		// not set
		if (!(object instanceof EcError)) {
			return false;
		}
		EcError other = (EcError) object;
		if ((this.errCod == null && other.errCod != null) || (this.errCod != null && !this.errCod.equals(other.errCod))) {
			return false;
		}
		return true;
	}

	@Override
	public String toString() {
		return "net.huadong.edi.log.domain.EcError[ errCod=" + errCod + " ]";
	}

}
