Represents an ongoing LE scan. More...
#include <central2.h>
Public Types | |
using | Ptr = internal::RaiiPtr< ScanHandle, &ScanHandle::Release > |
Public Member Functions | |
virtual | ~ScanHandle ()=default |
Stops the scan. | |
virtual async2::Poll< pw::Result< ScanResult > > | PendResult (async2::Context &cx)=0 |
Private Member Functions | |
virtual void | Release ()=0 |
Represents an ongoing LE scan.
using pw::bluetooth::low_energy::Central2::ScanHandle::Ptr = internal::RaiiPtr<ScanHandle, &ScanHandle::Release> |
Movable ScanHandle smart pointer. The controller will continue scanning until the ScanHandle::Ptr is destroyed.
|
pure virtual |
Returns the next ScanResult
if available. Otherwise, invokes cx.waker()
when a ScanResult
is available. Only one waker is supported at a time.
embed:rst:leading-asterisk * * .. pw-status-codes:: * * OK: ScanResult was returned. * * CANCELLED: An internal error occurred and the scan was cancelled. * *
|
privatepure virtual |
Stop the current scan. This method is called by the ~ScanHandlePtr() when it goes out of scope, the API client should never call this method.