package kr.co.icontrols.iotplatform.AWS;

import android.bluetooth.BluetoothDevice;

import java.util.Objects;

public class AmazonBLEinfo {
    private String name;
    private String macAddr;
    private BluetoothDevice mBluetoothDevice;

    public AmazonBLEinfo(String name, String macAddr, BluetoothDevice bluetoothDevice) {
        this.name = name;
        this.macAddr = macAddr;
        mBluetoothDevice = bluetoothDevice;
    }

    public BluetoothDevice getBluetoothDevice() {
        return mBluetoothDevice;
    }

    public void setBluetoothDevice(BluetoothDevice bluetoothDevice) {
        mBluetoothDevice = bluetoothDevice;
    }

    public String getName() {
        return name;
    }

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

    public String getMacAddr() {
        return macAddr;
    }

    public void setMacAddr(String macAddr) {
        this.macAddr = macAddr;
    }

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

    @Override
    public int hashCode() {

        return Objects.hash(getName(), getMacAddr(), getBluetoothDevice());
    }
}
