MCPcopy Create free account
hub / github.com/Tencent/MMKV / removeValueForKey

Function removeValueForKey

OpenHarmony/MMKV/src/main/cpp/native_bridge.cpp:1266–1278  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1264}
1265
1266static napi_value removeValueForKey(napi_env env, napi_callback_info info) {
1267 size_t argc = 2;
1268 napi_value args[2] = {nullptr};
1269 NAPI_CALL(napi_get_cb_info(env, info, &argc, args, nullptr, nullptr));
1270
1271 auto handle = NValueToUInt64(env, args[0]);
1272 auto key = NValueToString(env, args[1]);
1273 MMKV *kv = reinterpret_cast<MMKV *>(handle);
1274 if (kv && key.length() > 0) {
1275 kv->removeValueForKey(key);
1276 }
1277 return NAPIUndefined(env);
1278}
1279
1280static napi_value removeValuesForKeys(napi_env env, napi_callback_info info) {
1281 size_t argc = 2;

Callers

nothing calls this directly

Calls 4

NValueToUInt64Function · 0.85
NAPIUndefinedFunction · 0.85
NValueToStringFunction · 0.70
removeValueForKeyMethod · 0.45

Tested by

no test coverage detected