コード例 #1
0
  public void addJavascriptInterface(Object obj, String interfaceName) {
    assert obj != null;
    removeJavascriptInterface(interfaceName);

    mJavaScriptObjects.put(interfaceName, obj);
  }
コード例 #2
0
 public void addJavascriptInterface(Object obj, String interfaceName, boolean requireAnnotation) {
   assert obj != null;
   removeJavascriptInterface(interfaceName);
   mJavaScriptObjects.put(interfaceName, new JSObject(obj, requireAnnotation));
 }