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.
5 #include "base/android/jni_registrar.h"
7 #include "base/debug/trace_event.h"
8 #include "base/logging.h"
9 #include "base/android/jni_android.h"
14 bool RegisterNativeMethods(JNIEnv
* env
,
15 const RegistrationMethod
* method
,
17 TRACE_EVENT0("startup", "base_android::RegisterNativeMethods")
18 const RegistrationMethod
* end
= method
+ count
;
19 while (method
!= end
) {
20 if (!method
->func(env
)) {
21 DLOG(ERROR
) << method
->name
<< " failed registration!";
29 } // namespace android