jni_registrar.h 818 B

12345678910111213141516171819202122232425262728
  1. // Copyright (c) 2012 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #ifndef BASE_ANDROID_JNI_REGISTRAR_H_
  5. #define BASE_ANDROID_JNI_REGISTRAR_H_
  6. #include <jni.h>
  7. #include <stddef.h>
  8. #include "base/base_export.h"
  9. namespace base {
  10. namespace android {
  11. struct RegistrationMethod;
  12. // Registers the JNI bindings for the specified |method| definition containing
  13. // |count| elements. Returns whether the registration of the given methods
  14. // succeeded.
  15. BASE_EXPORT bool RegisterNativeMethods(JNIEnv* env,
  16. const RegistrationMethod* method,
  17. size_t count);
  18. } // namespace android
  19. } // namespace base
  20. #endif // BASE_ANDROID_JNI_REGISTRAR_H_