@Override protected void onStop() { super.onStop(); mFacadeManager.getReceiver(EventFacade.class).removeEventObserver(mObserver); mWebView.destroy(); finish(); }
private String generateAPIWrapper() { StringBuilder wrapper = new StringBuilder(); for (Class<? extends RpcReceiver> clazz : mFacadeManager.getRpcReceiverClasses()) { for (MethodDescriptor rpc : MethodDescriptor.collectFrom(clazz)) { wrapper.append(String.format(ANDROID_PROTOTYPE_JS, rpc.getName())); } } return wrapper.toString(); }