package com.tmerclub.cloud.common.bean;

import java.util.Objects;

/**
 * @author lanhai
 */
public class BmapPoint {
    /**
     * 经度
     */
    private double lng;
    /**
     * 纬度
     */
    private double lat;

    public BmapPoint() {

    }

    public BmapPoint(double lng, double lat) {
        this.lng = lng;
        this.lat = lat;
    }

    @Override
    public boolean equals(Object obj) {
        if (obj instanceof BmapPoint) {
            BmapPoint bmapPoint = (BmapPoint) obj;
            return bmapPoint.getLng() == lng && bmapPoint.getLat() == lat;
        } else {
            return false;
        }
    }

    @Override
    public int hashCode() {
        return Objects.hash(lng, lat);
    }

    public double getLng() {
        return lng;
    }

    public void setLng(double lng) {
        this.lng = lng;
    }

    public double getLat() {
        return lat;
    }

    public void setLat(double lat) {
        this.lat = lat;
    }
}
