|
| KallistoCoreImpl (kallisto::bluetooth::BluetoothScannerConfiguration &scanner_configuration, kallisto::bluetooth::BluetoothScannerFilter &scanner_filter) |
|
| ~KallistoCoreImpl () |
|
| KallistoCoreImpl (KallistoCoreImpl const &)=delete |
|
| KallistoCoreImpl (KallistoCoreImpl &&)=delete |
|
void | operator= (KallistoCoreImpl const &)=delete |
|
void | operator= (KallistoCoreImpl &&)=delete |
|
error::KallistoDetailedResult | registerBluetoothAdapterEventListener (bluetooth::BluetoothAdapterEventListener &listener) |
|
error::KallistoDetailedResult | unregisterBluetoothAdapterEventListener (bluetooth::BluetoothAdapterEventListener &listener) |
|
error::KallistoDetailedResult | setScannerConfiguration (bluetooth::BluetoothScannerConfiguration &configuration) |
|
const bluetooth::BluetoothScannerConfiguration * | getScannerConfiguration () |
|
error::KallistoDetailedResult | setScannerFilter (bluetooth::BluetoothScannerFilter &filter) |
|
const bluetooth::BluetoothScannerFilter * | getScannerFilter () |
|
error::KallistoDetailedResult | registerBluetoothScanEventListener (bluetooth::BluetoothScanEventListener &listener) |
|
error::KallistoDetailedResult | unregisterBluetoothScanEventListener (bluetooth::BluetoothScanEventListener &listener) |
|
std::vector< hardware::KallistoImpl * > | getDevices () |
|
error::KallistoDetailedResult | registerListener (hardware::KallistoEventListener &listener, hardware::Kallisto &kallisto) |
|
error::KallistoDetailedResult | unregisterListener (hardware::KallistoEventListener &listener, hardware::Kallisto &kallisto) |
|
error::KallistoDetailedResult | stayConnected (hardware::Kallisto &kallisto, bool enable) |
|
error::KallistoDetailedResult | registerSensorListener (hardware::SensorEventListener &listener, hardware::Sensor &sensor, std::map< std::string, const void *> parameters) |
|
error::KallistoDetailedResult | unregisterSensorListener (hardware::SensorEventListener &listener, hardware::Sensor &sensor) |
|
void | onAdapterConnected (bluetooth::BluetoothAdapter &adapter) |
|
void | onAdapterDisconnected (bluetooth::BluetoothAdapter &adapter) |
|
void | onAdapterEnabled (bluetooth::BluetoothAdapter &adapter) |
|
void | onAdapterEnableFailed (bluetooth::BluetoothAdapter &adapter, bluetooth::BluetoothAdapter::Listener::Error error) |
|
void | onAdapterDisabled (bluetooth::BluetoothAdapter &adapter) |
|
void | sendAdapterEvent (AdapterEventType type) |
|
void | onScanStart () |
|
void | onScanStartFailed () |
|
void | onScanStop (std::vector< kallisto::bluetooth::BluetoothDevice *> devices_found) |
|
void | onScan (bluetooth::BluetoothDevice &device, const bluetooth::BluetoothAdapter::ScanListener::ScanRecord record) |
|
void | sendScanEvent (ScanEventType type, hardware::Kallisto &device, const bluetooth::BluetoothAdapter::ScanListener::ScanRecord record) |
|
void | onLinkLoss (std::chrono::nanoseconds timestamp, hardware::Kallisto &device) |
|
void | onLinkRecovered (std::chrono::nanoseconds timestamp, hardware::Kallisto &device) |
|
void | onLinkRemoved (std::chrono::nanoseconds, hardware::Kallisto &device) |
|
void | sendKallistoEvent (KallistoEventType type) |
|
◆ KallistoCoreImpl() [1/2]
◆ ~KallistoCoreImpl()
◆ KallistoCoreImpl() [2/2]
◆ getDevices()
Get the current device list.
- Returns
- A list with the available devices.
◆ getScannerConfiguration()
Get the current scanner configuration.
- Returns
- The current scanner configuration or nullptr if the scanner is not available.
◆ getScannerFilter()
Get the current scanner filter.
- Returns
- The current filter configuration or nullptr if the scanner is not available.
◆ onAdapterConnected()
◆ onAdapterDisabled()
Called when a Bluetooth adapter is disconnected.
- Parameters
-
adapter | The disconnected adapter. |
Implements BluetoothAdapter::Listener.
◆ onAdapterDisconnected()
◆ onAdapterEnabled()
◆ onAdapterEnableFailed()
◆ onLinkLoss()
Called when the connection to a device under use is lost.
- Parameters
-
timestamp | The time at which the event happened in nanoseconds since the epoch. |
device | The device that generated the event. |
Reimplemented from KallistoEventListener.
◆ onLinkRecovered()
Called when the connection to a device under use is recovered.
- Parameters
-
timestamp | The time at which the event happened in nanoseconds since the epoch. |
device | The device that generated the event. |
Reimplemented from KallistoEventListener.
◆ onLinkRemoved()
Called when there is a timeout while waiting for connection recovery.
- Parameters
-
timestamp | The time at which the event happened in nanoseconds since the epoch. |
device | The device that generated the event. |
Implements KallistoEventListener.
◆ onScan()
◆ onScanStart()
◆ onScanStartFailed()
void onScanStartFailed |
( |
| ) |
|
|
virtual |
◆ onScanStop()
Called when a scan is stopped.
- Parameters
-
devices_found | List of devices found during the scan. |
- Note
- We have 3 states when this callback is called: 1 - Scanning normally. Will check if any Kallisto disappeared; 2 - Stopped current scan because a scan for Link Loss started; 3 - Stopped current scan because a scan for Link Loss ended and we should resume last scanning state
Implements BluetoothAdapter::ScanListener.
◆ registerBluetoothAdapterEventListener()
Registers a listener.
- Parameters
-
listener | A listener to receive bluetooth adapter events. |
- Returns
- A detailed result.
◆ registerBluetoothScanEventListener()
Registers a listener.
- Parameters
-
listener | A listener to receive bluetooth scan events. |
- Returns
- A detailed result.
◆ registerListener()
Registers a listener for the passed Kallisto.
- Parameters
-
listener | A listener to receive Kallisto events. |
kallisto | The Kallisto to register to. |
- Returns
- A detailed result.
◆ registerSensorListener()
Registers the passed sensor listener with the sensor with the passed handle.
- Parameters
-
handle | The sensor handle. |
parameters | The map of parameters. |
listener | The sensor listener. |
- Returns
- A detailed result.
◆ sendAdapterEvent()
void sendAdapterEvent |
( |
AdapterEventType |
type | ) |
|
Dispatch an adapter event to registered listeners.
- Parameters
-
type | The event type. Defines the callback to be called. |
◆ sendKallistoEvent()
void sendKallistoEvent |
( |
KallistoEventType |
type | ) |
|
Dispatch an Kallisto event to registered listeners.
- Parameters
-
type | The event type. Defines the callback to be called. |
◆ sendScanEvent()
Dispatch an scan event to registered listeners.
- Parameters
-
type | The event type. Defines the callback to be called. |
device | The device that generated the event |
record | Scan record |
◆ setScannerConfiguration()
Updates the scanner configuration.
- Parameters
-
- Returns
- A detailed result.
◆ setScannerFilter()
Updates the scanner filter.
- Parameters
-
- Returns
- A detailed result.
◆ stayConnected()
Signals that the system should keep a connection to the passed Kallisto even when not in use. Use the enable param to control this behaviour.
- Parameters
-
kallisto | The Kallisto to stay connected with. |
enable | If true, the system will maintain a connection to the device even when not in use. If the device is not connected it will connect right away. |
- Returns
- A detailed result.
◆ unregisterBluetoothAdapterEventListener()
Unregisters a previously registered listener.
- Parameters
-
- Returns
- A detailed result.
◆ unregisterBluetoothScanEventListener()
Unregisters a previously registered listener.
- Parameters
-
- Returns
- A detailed result.
◆ unregisterListener()
Unregisters the listener for the passed Kallisto.
- Parameters
-
listener | A listener to receive Kallisto events. |
kallisto | The Kallisto to register to. |
- Returns
- A detailed result.
◆ unregisterSensorListener()
Unregisters the passed sensor listener from the sensor with the passed handle.
- Parameters
-
handle | The sensor handle. |
listener | The sensor listener. |
- Returns
- A detailed result.
The documentation for this class was generated from the following file:
- /home/joao.oliveira/Workspace/local/repo/documentation/sphinx/source/components/kallistolinuxapi/include/core/kallisto_core_impl.hpp