Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(21)

Side by Side Diff: base/android/build_info.h

Issue 2202793002: base: Remove unneeded RegisterNatives() calls on Android (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@jnireg2
Patch Set: rebase Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « base/android/base_jni_registrar.cc ('k') | base/android/build_info.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef BASE_ANDROID_BUILD_INFO_H_ 5 #ifndef BASE_ANDROID_BUILD_INFO_H_
6 #define BASE_ANDROID_BUILD_INFO_H_ 6 #define BASE_ANDROID_BUILD_INFO_H_
7 7
8 #include <jni.h> 8 #include <jni.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 } 103 }
104 104
105 const char* java_exception_info() const { 105 const char* java_exception_info() const {
106 return java_exception_info_; 106 return java_exception_info_;
107 } 107 }
108 108
109 void SetJavaExceptionInfo(const std::string& info); 109 void SetJavaExceptionInfo(const std::string& info);
110 110
111 void ClearJavaExceptionInfo(); 111 void ClearJavaExceptionInfo();
112 112
113 static bool RegisterBindings(JNIEnv* env);
114
115 private: 113 private:
116 friend struct BuildInfoSingletonTraits; 114 friend struct BuildInfoSingletonTraits;
117 115
118 explicit BuildInfo(JNIEnv* env); 116 explicit BuildInfo(JNIEnv* env);
119 117
120 // Const char* is used instead of std::strings because these values must be 118 // Const char* is used instead of std::strings because these values must be
121 // available even if the process is in a crash state. Sadly 119 // available even if the process is in a crash state. Sadly
122 // std::string.c_str() doesn't guarantee that memory won't be allocated when 120 // std::string.c_str() doesn't guarantee that memory won't be allocated when
123 // it is called. 121 // it is called.
124 const char* const device_; 122 const char* const device_;
(...skipping 12 matching lines...) Expand all
137 // This is set via set_java_exception_info, not at constructor time. 135 // This is set via set_java_exception_info, not at constructor time.
138 const char* java_exception_info_; 136 const char* java_exception_info_;
139 137
140 DISALLOW_COPY_AND_ASSIGN(BuildInfo); 138 DISALLOW_COPY_AND_ASSIGN(BuildInfo);
141 }; 139 };
142 140
143 } // namespace android 141 } // namespace android
144 } // namespace base 142 } // namespace base
145 143
146 #endif // BASE_ANDROID_BUILD_INFO_H_ 144 #endif // BASE_ANDROID_BUILD_INFO_H_
OLDNEW
« no previous file with comments | « base/android/base_jni_registrar.cc ('k') | base/android/build_info.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698