package sicura.entities;
// Generated 2-lug-2017 12.20.06 by Hibernate Tools 5.2.3.Final

import javax.persistence.Column;
import javax.persistence.Embeddable;

/**
 * ApCabTempId generated by hbm2java
 */
@Embeddable
public class ApCabTempId implements java.io.Serializable {

	private String abi;
	private String cab;

	public ApCabTempId() {
	}

	public ApCabTempId(String abi, String cab) {
		this.abi = abi;
		this.cab = cab;
	}

	@Column(name = "ABI", nullable = false, length = 5)
	public String getAbi() {
		return this.abi;
	}

	public void setAbi(String abi) {
		this.abi = abi;
	}

	@Column(name = "CAB", nullable = false, length = 5)
	public String getCab() {
		return this.cab;
	}

	public void setCab(String cab) {
		this.cab = cab;
	}

	public boolean equals(Object other) {
		if ((this == other))
			return true;
		if ((other == null))
			return false;
		if (!(other instanceof ApCabTempId))
			return false;
		ApCabTempId castOther = (ApCabTempId) other;

		return ((this.getAbi() == castOther.getAbi())
				|| (this.getAbi() != null && castOther.getAbi() != null && this.getAbi().equals(castOther.getAbi())))
				&& ((this.getCab() == castOther.getCab()) || (this.getCab() != null && castOther.getCab() != null
						&& this.getCab().equals(castOther.getCab())));
	}

	public int hashCode() {
		int result = 17;

		result = 37 * result + (getAbi() == null ? 0 : this.getAbi().hashCode());
		result = 37 * result + (getCab() == null ? 0 : this.getCab().hashCode());
		return result;
	}

}
