package vn.azteam.tpf.service.dto;

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

/**
 * A DTO for the TBDistrict entity.
 */
public class TBDistrictDTO implements Serializable {

    private Long id;

    private String name;

    private Long tbCityId;

    public Long getId() {
        return id;
    }

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

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Long getTbCityId() {
        return tbCityId;
    }

    public void setTbCityId(Long tBCityId) {
        this.tbCityId = tBCityId;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }

        TBDistrictDTO tBDistrictDTO = (TBDistrictDTO) o;
        if (tBDistrictDTO.getId() == null || getId() == null) {
            return false;
        }
        return Objects.equals(getId(), tBDistrictDTO.getId());
    }

    @Override
    public int hashCode() {
        return Objects.hashCode(getId());
    }

    @Override
    public String toString() {
        return "TBDistrictDTO{" +
            "id=" + getId() +
            ", name='" + getName() + "'" +
            ", tbCity=" + getTbCityId() +
            "}";
    }
}
