-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathUtils.h
More file actions
31 lines (26 loc) · 1.03 KB
/
Copy pathUtils.h
File metadata and controls
31 lines (26 loc) · 1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#pragma once
#include <string>
#include <vector>
#include <locale>
// Forwards
struct _GUID;
typedef _GUID GUID;
struct _BTH_LE_UUID;
typedef _BTH_LE_UUID BTH_LE_UUID;
namespace BLEUtils
{
std::string ToNarrow(const wchar_t *s, char def = '?', const std::locale& loc = std::locale());
std::wstring ToWide(const char *s, const std::locale& loc = std::locale());
std::string GUIDToString(GUID guid);
std::string BTHLEGUIDToString(const BTH_LE_UUID& bth_le_uuid);
BTH_LE_UUID StringToBTHLEUUID(const std::string& guid);
GUID StringToGUID(const std::string& guid);
GUID BTHLEGUIDToGUID(const BTH_LE_UUID& bth_le_uuid);
BTH_LE_UUID GUIDToBTHLEGUID(const GUID& guid);
std::vector<BTH_LE_UUID> GenerateGUIDList(const char* uuidString);
std::string Base64Encode(unsigned char const* bytes_to_encode, unsigned int in_len);
std::string Base64Decode(std::string const& encoded_string);
BTH_LE_UUID MakeBTHLEUUID(USHORT shortId);
}
bool operator==(const BTH_LE_UUID& a, const BTH_LE_UUID& b);
bool operator!=(const BTH_LE_UUID& a, const BTH_LE_UUID& b);