Java 类com.facebook.react.bridge.NoSuchKeyException 实例源码

项目:RNLearn_Project1    文件:CatalystNativeJSToJavaParametersTestCase.java   
private void assertNoSuchKeyExceptionThrown(
    ReadableMap map,
    String key,
    String typeToAskFor) {
  boolean gotException = false;
  try {
    mapGetByType(map, key, typeToAskFor);
  } catch (NoSuchKeyException expected) {
    gotException = true;
  }

  assertTrue(gotException);
}
项目:RNLearn_Project1    文件:CatalystNativeJSToJavaParametersTestCase.java   
private void assertNoSuchKeyExceptionThrown(
    ReadableMap map,
    String key,
    String typeToAskFor) {
  boolean gotException = false;
  try {
    mapGetByType(map, key, typeToAskFor);
  } catch (NoSuchKeyException expected) {
    gotException = true;
  }

  assertTrue(gotException);
}
项目:Ironman    文件:CatalystNativeJSToJavaParametersTestCase.java   
private void assertNoSuchKeyExceptionThrown(
    ReadableMap map,
    String key,
    String typeToAskFor) {
  boolean gotException = false;
  try {
    mapGetByType(map, key, typeToAskFor);
  } catch (NoSuchKeyException expected) {
    gotException = true;
  }

  assertTrue(gotException);
}
项目:react-native-update    文件:Utils.java   
public static String tryGetString(ReadableMap map, String key) {
    try {
        return map.getString(key);
    } catch (NoSuchKeyException e) {
        return null;
    }
}