Direct-BT  2.3.1
Direct-BT - Direct Bluetooth Programming.
Public Member Functions | List of all members
DelegatedBTGattCharListener Class Reference
Inheritance diagram for DelegatedBTGattCharListener:
Collaboration diagram for DelegatedBTGattCharListener:

Public Member Functions

 DelegatedBTGattCharListener (const BTGattChar *characteristicMatch, std::shared_ptr< BTGattChar::Listener > l) noexcept
 
bool match (const BTGattChar &characteristic) noexcept override
 Custom filter for all event methods, which will not be called if this method returns false. More...
 
void notificationReceived (BTGattCharRef charDecl, const TROOctets &charValue, const uint64_t timestamp) override
 Called from native BLE stack, initiated by a received notification associated with the given BTGattChar. More...
 
void indicationReceived (BTGattCharRef charDecl, const TROOctets &charValue, const uint64_t timestamp, const bool confirmationSent) override
 Called from native BLE stack, initiated by a received indication associated with the given BTGattChar. More...
 
bool operator== (const DelegatedBTGattCharListener &rhs) const noexcept
 
bool operator!= (const DelegatedBTGattCharListener &rhs) const noexcept
 
- Public Member Functions inherited from direct_bt::BTGattCharListener
virtual ~BTGattCharListener () noexcept
 
virtual bool operator== (const BTGattCharListener &rhs) const noexcept
 Default comparison operator, merely testing for same memory reference. More...
 
bool operator!= (const BTGattCharListener &rhs) const noexcept
 

Detailed Description

Definition at line 251 of file BTGattChar.cpp.

Constructor & Destructor Documentation

◆ DelegatedBTGattCharListener()

DelegatedBTGattCharListener::DelegatedBTGattCharListener ( const BTGattChar characteristicMatch,
std::shared_ptr< BTGattChar::Listener l 
)
inlinenoexcept

Definition at line 257 of file BTGattChar.cpp.

Member Function Documentation

◆ indicationReceived()

void DelegatedBTGattCharListener::indicationReceived ( BTGattCharRef  charDecl,
const TROOctets charValue,
const uint64_t  timestamp,
const bool  confirmationSent 
)
inlineoverridevirtual

Called from native BLE stack, initiated by a received indication associated with the given BTGattChar.

Parameters
charDeclBTGattChar related to this indication
charValuethe indication value
timestampthe indication monotonic timestamp, see BluetoothUtils#getCurrentMilliseconds()
confirmationSentif true, the native stack has sent the confirmation, otherwise user is required to do so.

Implements direct_bt::BTGattCharListener.

Definition at line 272 of file BTGattChar.cpp.

Here is the call graph for this function:

◆ match()

bool DelegatedBTGattCharListener::match ( const BTGattChar characteristic)
inlineoverridevirtualnoexcept

Custom filter for all event methods, which will not be called if this method returns false.

User may override this method to test whether the methods shall be called for the given BTGattChar.

Defaults to true;

Reimplemented from direct_bt::BTGattCharListener.

Definition at line 260 of file BTGattChar.cpp.

◆ notificationReceived()

void DelegatedBTGattCharListener::notificationReceived ( BTGattCharRef  charDecl,
const TROOctets charValue,
const uint64_t  timestamp 
)
inlineoverridevirtual

Called from native BLE stack, initiated by a received notification associated with the given BTGattChar.

Parameters
charDeclBTGattChar related to this notification
charValuethe notification value
timestampthe indication monotonic timestamp, see getCurrentMilliseconds()

Implements direct_bt::BTGattCharListener.

Definition at line 267 of file BTGattChar.cpp.

Here is the call graph for this function:

◆ operator!=()

bool DelegatedBTGattCharListener::operator!= ( const DelegatedBTGattCharListener rhs) const
inlinenoexcept

Definition at line 281 of file BTGattChar.cpp.

◆ operator==()

bool DelegatedBTGattCharListener::operator== ( const DelegatedBTGattCharListener rhs) const
inlinenoexcept

Definition at line 278 of file BTGattChar.cpp.


The documentation for this class was generated from the following file: