nl::Weave::DeviceLayer::Internal::GenericConnectivityManagerImpl_NoBLE

#include <src/adaptations/device-layer/include/Weave/DeviceLayer/internal/GenericConnectivityManagerImpl_NoBLE.h>

針對不支援 BLE 的平台,提供 BLE 專屬的 ConnectivityManager 功能的一般實作。

摘要

此類別是要由 ConnectivityManagerImpl 類別直接繼承 (直接或間接沿用),而該類別也會顯示為範本的 ImplClass 參數。

這個類別的成員都是不會執行任何動作的內嵌方法,會傳回靜態傳回值。這樣一來,編譯器就能在不使用 #ifdef 的情況下,最佳化無用程式碼。例如:

``` if (ConnectivityMgr().GetWoBLEServiceMode() != ConnectivityManager::kWoBLEServiceMode_NotSupported) { // ... do something on devices that support WoBLE ... } ```

公開函式

_GetBLEDeviceName(char *buf, size_t bufSize)
_GetWoBLEServiceMode(void)
ConnectivityManager::WoBLEServiceMode
_IsBLEAdvertisingEnabled(void)
bool
_IsBLEFastAdvertisingEnabled(void)
bool
_NumBLEConnections(void)
uint16_t
_SetBLEAdvertisingEnabled(bool val)
_SetBLEDeviceName(const char *deviceName)
_SetBLEFastAdvertisingEnabled(bool val)
_SetWoBLEServiceMode(ConnectivityManager::WoBLEServiceMode val)

公開的靜態函式

_WoBLEServiceModeToStr(ConnectivityManager::WoBLEServiceMode mode)
const char *

公開函式

_GetBLEDeviceName

WEAVE_ERROR _GetBLEDeviceName(
  char *buf,
  size_t bufSize
)

_GetWoBLEServiceMode

ConnectivityManager::WoBLEServiceMode _GetWoBLEServiceMode(
  void
)

_IsBLEAdvertisingEnabled

bool _IsBLEAdvertisingEnabled(
  void
)

_IsBLEFastAdvertisingEnabled

bool _IsBLEFastAdvertisingEnabled(
  void
)

_NumBLEConnections

uint16_t _NumBLEConnections(
  void
)

_SetBLEAdvertisingEnabled

WEAVE_ERROR _SetBLEAdvertisingEnabled(
  bool val
)

_SetBLEDeviceName

WEAVE_ERROR _SetBLEDeviceName(
  const char *deviceName
)

_SetBLEFastAdvertisingEnabled

WEAVE_ERROR _SetBLEFastAdvertisingEnabled(
  bool val
)

_SetWoBLEServiceMode

WEAVE_ERROR _SetWoBLEServiceMode(
  ConnectivityManager::WoBLEServiceMode val
)

公開的靜態函式

_WoBLEServiceModeToStr

const char * _WoBLEServiceModeToStr(
  ConnectivityManager::WoBLEServiceMode mode
)