| 91 | } |
| 92 | |
| 93 | static 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 | |
| 105 | template<typename T> |
| 106 | static std::optional<T> jniGetMapPropertyAndReturnValue( |
no test coverage detected