42 #ifndef BLUETOOTH_DEVICE_HPP    43 #define BLUETOOTH_DEVICE_HPP    48 #include "../../util/error/kallisto_error.hpp"    54 class BluetoothDeviceNative; 
    59 class BluetoothDevice : 
public BluetoothDispatcher {
    69     std::unique_ptr<BluetoothDeviceNative> m_native_implementation;
    74     std::string m_address;
   124     error::KallistoDetailedResult 
connect(ConnectionListener listener);
   131     error::KallistoDetailedResult 
disconnect(
bool no_callback);
   148     error::KallistoDetailedResult 
getRssi(
int& buffer);
   151     error::KallistoDetailedResult 
readCharacteristic(std::string service_uuid, std::string characteristic_uuid, std::vector<unsigned char>& buffer);
   152     error::KallistoDetailedResult 
writeCharacteristic(std::string service_uuid, std::string characteristic_uuid, std::vector<unsigned char>& buffer);
   153     error::KallistoDetailedResult 
enableNotification(std::string service_uuid, std::string characteristic_uuid, BluetoothDispatcher::NotificationListener& listener);
   154     error::KallistoDetailedResult 
disableNotification(std::string service_uuid, std::string characteristic_uuid, BluetoothDispatcher::NotificationListener& listener);
   157        return (this->
getAddress() == other.getAddress());
   161         return !(*
this == other);
   168 #endif // BLUETOOTH_DEVICE_HPP std::vector< std::string > getServices()
Definition: bluetooth_adapter.hpp:52
std::string getAddress() const
Definition: bluetooth_device.hpp:114
error::KallistoDetailedResult disableNotification(std::string service_uuid, std::string characteristic_uuid, BluetoothDispatcher::NotificationListener &listener)
std::vector< std::string > getCharacteristics(std::string service_uuid)
error::KallistoDetailedResult getRssi(int &buffer)
error::KallistoDetailedResult enableNotification(std::string service_uuid, std::string characteristic_uuid, BluetoothDispatcher::NotificationListener &listener)
error::KallistoDetailedResult disconnect(bool no_callback)
std::string getName() const
Definition: bluetooth_device.hpp:106
BluetoothDevice(std::string name, std::string address)
virtual ~BluetoothDevice()
error::KallistoDetailedResult readCharacteristic(std::string service_uuid, std::string characteristic_uuid, std::vector< unsigned char > &buffer)
std::function< void(bool connected)> ConnectionListener
Definition: bluetooth_device.hpp:64
error::KallistoDetailedResult connect(ConnectionListener listener)
error::KallistoDetailedResult writeCharacteristic(std::string service_uuid, std::string characteristic_uuid, std::vector< unsigned char > &buffer)