| 53 | api_object_impl &operator=(const api_object_impl &) = delete; |
| 54 | |
| 55 | void get_private_data(const uint8_t guid[16], uint64_t *data) const final |
| 56 | { |
| 57 | assert(data != nullptr); |
| 58 | |
| 59 | if (_private_data.empty()) // Early-out to avoid crash when this is called after the object was destroyed |
| 60 | { |
| 61 | *data = 0; |
| 62 | return; |
| 63 | } |
| 64 | |
| 65 | if (const auto it = _private_data.find(*reinterpret_cast<const guid_t *>(guid)); |
| 66 | it != _private_data.end()) |
| 67 | *data = it->second; |
| 68 | else |
| 69 | *data = 0; |
| 70 | } |
| 71 | void set_private_data(const uint8_t guid[16], const uint64_t data) final |
| 72 | { |
| 73 | if (data != 0) |