MCPcopy Create free account
hub / github.com/Snapchat/Valdi / jniGetMapProperty

Function jniGetMapProperty

valdi/src/valdi/android/MarshallerJNI.cpp:93–103  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

91}
92
93static bool jniGetMapProperty(JNIEnv* env, Valdi::Marshaller* marshaller, jlong propPtr, jint index, bool optional) {
94 auto propStrCpp = ValdiAndroid::unwrapInternedString(propPtr);
95 if (optional) {
96 return marshaller->getMapProperty(
97 propStrCpp, static_cast<int>(index), Valdi::Marshaller::GetMapPropertyFlags::IgnoreNullOrUndefined);
98 } else {
99 marshaller->mustGetMapProperty(
100 propStrCpp, static_cast<int>(index), Valdi::Marshaller::GetMapPropertyFlags::IgnoreNullOrUndefined);
101 return checkMarshaller(env, marshaller);
102 }
103}
104
105template<typename T>
106static std::optional<T> jniGetMapPropertyAndReturnValue(

Callers 1

Calls 4

unwrapInternedStringFunction · 0.85
checkMarshallerFunction · 0.85
mustGetMapPropertyMethod · 0.80
getMapPropertyMethod · 0.45

Tested by

no test coverage detected