Lines Matching refs:hci

25 namespace hci {
36 template <typename T, typename std::enable_if<std::is_same_v<T, hci::DeviceType>, int>::type = 0>
37 std::optional<hci::DeviceType> FromLegacyConfigString(const std::string& str) { in FromLegacyConfigString()
42 if (*raw_value < hci::DeviceType::UNKNOWN || *raw_value > hci::DeviceType::DUAL) { in FromLegacyConfigString()
45 return static_cast<hci::DeviceType>(*raw_value); in FromLegacyConfigString()
49 template <typename T, typename std::enable_if<std::is_same_v<T, hci::AddressType>, int>::type = 0>
50 std::optional<hci::AddressType> FromLegacyConfigString(const std::string& str) { in FromLegacyConfigString()
55 if (*raw_value < static_cast<int64_t>(hci::AddressType::PUBLIC_DEVICE_ADDRESS) || in FromLegacyConfigString()
56 *raw_value > static_cast<int64_t>(hci::AddressType::RANDOM_IDENTITY_ADDRESS)) { in FromLegacyConfigString()
59 return static_cast<hci::AddressType>(*raw_value); in FromLegacyConfigString()
63 template <typename T, typename std::enable_if<std::is_same_v<T, hci::KeyType>, int>::type = 0>
64 std::optional<hci::KeyType> FromLegacyConfigString(const std::string& str) { in FromLegacyConfigString()
69 if (*raw_value < static_cast<int64_t>(hci::KeyType::COMBINATION) || in FromLegacyConfigString()
70 *raw_value > static_cast<int64_t>(hci::KeyType::AUTHENTICATED_P256)) { in FromLegacyConfigString()
73 return static_cast<hci::KeyType>(*raw_value); in FromLegacyConfigString()
77 template <typename T, typename std::enable_if<std::is_same_v<T, hci::LegacyScanMode>, int>::type = …
78 std::optional<hci::LegacyScanMode> FromLegacyConfigString(const std::string& str) { in FromLegacyConfigString()
83 if (*raw_value < static_cast<int64_t>(hci::LegacyScanMode::BT_SCAN_MODE_NONE) || in FromLegacyConfigString()
84 … *raw_value > static_cast<int64_t>(hci::LegacyScanMode::BT_SCAN_MODE_CONNECTABLE_DISCOVERABLE)) { in FromLegacyConfigString()
87 return static_cast<hci::LegacyScanMode>(*raw_value); in FromLegacyConfigString()