package com.sun.ts.tests.jpa.core.override.entitylistener;

import javax.persistence.Entity;
import javax.persistence.EntityListeners;
import javax.persistence.Id;
import javax.persistence.Table;

@Entity
@EntityListeners(com.sun.ts.tests.jpa.core.override.entitylistener.ListenerD.class)
@Table(name = "NOENTITYLISTENER_TABLE")
public class NoEntityListener implements java.io.Serializable {

    private Long id;

    public NoEntityListener() {
    }

    @Id
    public Long getId() {
        return id;
    }

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

    public int hashCode() {
        int hash = 0;
        hash += (this.id != null ? this.id.hashCode() : 0);
        return hash;
    }

    public boolean equals(Object object) {
        if (!(object instanceof NoEntityListener)) {
            return false;
        }
        NoEntityListener other = (NoEntityListener) object;
        if (this.id != other.id &&
                (this.id == null || !this.id.equals(other.id))) {
            return false;
        }
        return true;
    }

    public String toString() {
        return "com.sun.ts.tests.jpa.core.override." +
                "entitylistener.NoEntityListener id=" + id;
    }
}
