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

Function doCheckReSetCryptKey

Android/MMKV/mmkv/src/main/cpp/native-bridge.cpp:943–957  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

941}
942
943MMKV_JNI void doCheckReSetCryptKey(JNIEnv *env, jobject instance, jstring cryptKey, jboolean aes256) {
944 MMKV *kv = getMMKV(env, instance);
945 if (kv) {
946 string newKey;
947 if (cryptKey) {
948 newKey = jstring2string(env, cryptKey);
949 }
950
951 if (!cryptKey || newKey.empty()) {
952 kv->checkReSetCryptKey(nullptr, aes256);
953 } else {
954 kv->checkReSetCryptKey(&newKey, aes256);
955 }
956 }
957}
958
959# else
960

Callers

nothing calls this directly

Calls 3

getMMKVFunction · 0.85
jstring2stringFunction · 0.70
checkReSetCryptKeyMethod · 0.45

Tested by

no test coverage detected