| 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_AUTOFILL_ANDROID_PERSONAL_DATA_MANAGER_ANDROID_H_ | 5 #ifndef CHROME_BROWSER_AUTOFILL_ANDROID_PERSONAL_DATA_MANAGER_ANDROID_H_ |
| 6 #define CHROME_BROWSER_AUTOFILL_ANDROID_PERSONAL_DATA_MANAGER_ANDROID_H_ | 6 #define CHROME_BROWSER_AUTOFILL_ANDROID_PERSONAL_DATA_MANAGER_ANDROID_H_ |
| 7 | 7 |
| 8 #include "base/android/jni_weak_ref.h" | 8 #include "base/android/jni_weak_ref.h" |
| 9 #include "base/android/scoped_java_ref.h" | 9 #include "base/android/scoped_java_ref.h" |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 97 const base::android::JavaParamRef<jstring>& jguid); | 97 const base::android::JavaParamRef<jstring>& jguid); |
| 98 | 98 |
| 99 // Adds or modifies a local credit card. If |jguid| is an empty string, we | 99 // Adds or modifies a local credit card. If |jguid| is an empty string, we |
| 100 // are creating a new card. Else we are updating an existing profile. Always | 100 // are creating a new card. Else we are updating an existing profile. Always |
| 101 // returns the GUID for this profile; the GUID it may have just been created. | 101 // returns the GUID for this profile; the GUID it may have just been created. |
| 102 base::android::ScopedJavaLocalRef<jstring> SetCreditCard( | 102 base::android::ScopedJavaLocalRef<jstring> SetCreditCard( |
| 103 JNIEnv* env, | 103 JNIEnv* env, |
| 104 const base::android::JavaParamRef<jobject>& unused_obj, | 104 const base::android::JavaParamRef<jobject>& unused_obj, |
| 105 const base::android::JavaParamRef<jobject>& jcard); | 105 const base::android::JavaParamRef<jobject>& jcard); |
| 106 | 106 |
| 107 // Updates the billing address of a server credit card with GUID |jguid|. |
| 108 void UpdateServerCardBillingAddress(JNIEnv* env, |
| 109 const base::android::JavaParamRef<jobject>& unused_obj, |
| 110 const base::android::JavaParamRef<jstring>& jguid, |
| 111 const base::android::JavaParamRef<jstring>& jbilling_address_id); |
| 112 |
| 107 // Adds a server credit card. Used only in tests. | 113 // Adds a server credit card. Used only in tests. |
| 108 void AddServerCreditCardForTest( | 114 void AddServerCreditCardForTest( |
| 109 JNIEnv* env, | 115 JNIEnv* env, |
| 110 const base::android::JavaParamRef<jobject>& unused_obj, | 116 const base::android::JavaParamRef<jobject>& unused_obj, |
| 111 const base::android::JavaParamRef<jobject>& jcard); | 117 const base::android::JavaParamRef<jobject>& jcard); |
| 112 | 118 |
| 113 // Removes the profile or credit card represented by |jguid|. | 119 // Removes the profile or credit card represented by |jguid|. |
| 114 void RemoveByGUID(JNIEnv* env, | 120 void RemoveByGUID(JNIEnv* env, |
| 115 const base::android::JavaParamRef<jobject>& unused_obj, | 121 const base::android::JavaParamRef<jobject>& unused_obj, |
| 116 const base::android::JavaParamRef<jstring>& jguid); | 122 const base::android::JavaParamRef<jstring>& jguid); |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 189 | 195 |
| 190 // Pointer to the PersonalDataManager for the main profile. | 196 // Pointer to the PersonalDataManager for the main profile. |
| 191 PersonalDataManager* personal_data_manager_; | 197 PersonalDataManager* personal_data_manager_; |
| 192 | 198 |
| 193 DISALLOW_COPY_AND_ASSIGN(PersonalDataManagerAndroid); | 199 DISALLOW_COPY_AND_ASSIGN(PersonalDataManagerAndroid); |
| 194 }; | 200 }; |
| 195 | 201 |
| 196 } // namespace autofill | 202 } // namespace autofill |
| 197 | 203 |
| 198 #endif // CHROME_BROWSER_AUTOFILL_ANDROID_PERSONAL_DATA_MANAGER_ANDROID_H_ | 204 #endif // CHROME_BROWSER_AUTOFILL_ANDROID_PERSONAL_DATA_MANAGER_ANDROID_H_ |
| OLD | NEW |