Index: base/android/jni_generator/testNativesLong.golden |
diff --git a/base/android/jni_generator/testNativesLong.golden b/base/android/jni_generator/testNativesLong.golden |
new file mode 100644 |
index 0000000000000000000000000000000000000000..422e8458345b7ac2e0e86e04e067a14237849421 |
--- /dev/null |
+++ b/base/android/jni_generator/testNativesLong.golden |
@@ -0,0 +1,63 @@ |
+// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+// This file is autogenerated by |
+// base/android/jni_generator/jni_generator.py |
+// For |
+// org/chromium/TestJni |
+ |
+#ifndef org_chromium_TestJni_JNI |
+#define org_chromium_TestJni_JNI |
+ |
+#include <jni.h> |
+ |
+#include "base/android/jni_android.h" |
+#include "base/android/scoped_java_ref.h" |
+#include "base/basictypes.h" |
+#include "base/logging.h" |
+ |
+using base::android::ScopedJavaLocalRef; |
+ |
+// Step 1: forward declarations. |
+namespace { |
+const char kTestJniClassPath[] = "org/chromium/TestJni"; |
+// Leaking this jclass as we cannot use LazyInstance from some threads. |
+jclass g_TestJni_clazz = NULL; |
+} // namespace |
+ |
+// Step 2: method stubs. |
+static void Destroy(JNIEnv* env, jobject obj, |
+ jlong nativeChromeBrowserProvider) { |
+ DCHECK(nativeChromeBrowserProvider) << "Destroy"; |
+ ChromeBrowserProvider* native = |
+ reinterpret_cast<ChromeBrowserProvider*>(nativeChromeBrowserProvider); |
+ return native->Destroy(env, obj); |
+} |
+ |
+// Step 3: RegisterNatives. |
+ |
+static bool RegisterNativesImpl(JNIEnv* env) { |
+ |
+ g_TestJni_clazz = reinterpret_cast<jclass>(env->NewGlobalRef( |
+ base::android::GetClass(env, kTestJniClassPath).obj())); |
+ static const JNINativeMethod kMethodsTestJni[] = { |
+ { "nativeDestroy", |
+"(" |
+"J" |
+")" |
+"V", reinterpret_cast<void*>(Destroy) }, |
+ }; |
+ const int kMethodsTestJniSize = arraysize(kMethodsTestJni); |
+ |
+ if (env->RegisterNatives(g_TestJni_clazz, |
+ kMethodsTestJni, |
+ kMethodsTestJniSize) < 0) { |
+ LOG(ERROR) << "RegisterNatives failed in " << __FILE__; |
+ return false; |
+ } |
+ |
+ return true; |
+} |
+ |
+#endif // org_chromium_TestJni_JNI |