package de.votian.services.entity;

import java.io.Serializable;
import java.util.Objects;

public class CustomerServiceTypeAssignmentId implements Serializable {

    private Long customerId;
    private Long serviceTypeId;

    public CustomerServiceTypeAssignmentId() {
    }

    public CustomerServiceTypeAssignmentId(Long customerId, Long serviceTypeId) {
        this.customerId = customerId;
        this.serviceTypeId = serviceTypeId;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }
        CustomerServiceTypeAssignmentId that = (CustomerServiceTypeAssignmentId) o;
        return Objects.equals(customerId, that.customerId) && Objects.equals(serviceTypeId, that.serviceTypeId);
    }

    @Override
    public int hashCode() {
        return Objects.hash(customerId, serviceTypeId);
    }
}
