MCPcopy Create free account
hub / github.com/EasyIME/PIME / uuidToString

Function uuidToString

PIMETextService/PIMEClient.cpp:39–49  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

37namespace PIME {
38
39static std::string uuidToString(const UUID& uuid) {
40 std::string result;
41 LPOLESTR buf = nullptr;
42 if (SUCCEEDED(::StringFromCLSID(uuid, &buf))) {
43 result = utf16ToUtf8(buf);
44 ::CoTaskMemFree(buf);
45 // convert GUID to lwoer case
46 transform(result.begin(), result.end(), result.begin(), tolower);
47 }
48 return result;
49}
50
51bool uuidFromString(const char* uuidStr, UUID& result) {
52 std::wstring utf16UuidStr = utf8ToUtf16(uuidStr);

Callers 3

ClientMethod · 0.85
onPreservedKeyMethod · 0.85
onCompartmentChangedMethod · 0.85

Calls 2

beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected