Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_ANDROID_H_ | 5 #ifndef CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_ANDROID_H_ |
| 6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_ANDROID_H_ | 6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_ANDROID_H_ |
| 7 | 7 |
| 8 #include <jni.h> | 8 #include <jni.h> |
| 9 #include <map> | 9 #include <map> |
| 10 | 10 |
| (...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 186 base::android::ScopedJavaLocalRef<jstring> GetAboutInfoForTest(JNIEnv* env, | 186 base::android::ScopedJavaLocalRef<jstring> GetAboutInfoForTest(JNIEnv* env, |
| 187 jobject obj); | 187 jobject obj); |
| 188 | 188 |
| 189 // Returns the integer value corresponding to the current auth error state | 189 // Returns the integer value corresponding to the current auth error state |
| 190 // (GoogleServiceAuthError.State). | 190 // (GoogleServiceAuthError.State). |
| 191 jint GetAuthError(JNIEnv* env, jobject obj); | 191 jint GetAuthError(JNIEnv* env, jobject obj); |
| 192 | 192 |
| 193 // ProfileSyncServiceObserver: | 193 // ProfileSyncServiceObserver: |
| 194 virtual void OnStateChanged() OVERRIDE; | 194 virtual void OnStateChanged() OVERRIDE; |
| 195 | 195 |
| 196 jlong GetLastSyncedTimeForTest(JNIEnv* env, jobject obj); | |
|
Nicolas Zea
2013/08/30 22:32:18
add comment?
nyquist
2013/09/04 15:26:36
Done.
| |
| 197 | |
| 196 static ProfileSyncServiceAndroid* GetProfileSyncServiceAndroid(); | 198 static ProfileSyncServiceAndroid* GetProfileSyncServiceAndroid(); |
| 197 | 199 |
| 198 // Registers the ProfileSyncServiceAndroid's native methods through JNI. | 200 // Registers the ProfileSyncServiceAndroid's native methods through JNI. |
| 199 static bool Register(JNIEnv* env); | 201 static bool Register(JNIEnv* env); |
| 200 | 202 |
| 201 private: | 203 private: |
| 202 typedef std::map<invalidation::ObjectId, | 204 typedef std::map<invalidation::ObjectId, |
| 203 int64, | 205 int64, |
| 204 syncer::ObjectIdLessThan> ObjectIdVersionMap; | 206 syncer::ObjectIdLessThan> ObjectIdVersionMap; |
| 205 | 207 |
| (...skipping 17 matching lines...) Expand all Loading... | |
| 223 | 225 |
| 224 // The invalidation API spec allows for the possibility of redundant | 226 // The invalidation API spec allows for the possibility of redundant |
| 225 // invalidations, so keep track of the max versions and drop | 227 // invalidations, so keep track of the max versions and drop |
| 226 // invalidations with old versions. | 228 // invalidations with old versions. |
| 227 ObjectIdVersionMap max_invalidation_versions_; | 229 ObjectIdVersionMap max_invalidation_versions_; |
| 228 | 230 |
| 229 DISALLOW_COPY_AND_ASSIGN(ProfileSyncServiceAndroid); | 231 DISALLOW_COPY_AND_ASSIGN(ProfileSyncServiceAndroid); |
| 230 }; | 232 }; |
| 231 | 233 |
| 232 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_ANDROID_H_ | 234 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_ANDROID_H_ |
| OLD | NEW |