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 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
54 // distinguishing the profiles from one another. | 54 // distinguishing the profiles from one another. |
55 // | 55 // |
56 // The labels never contain the full name and include at least 2 fields. | 56 // The labels never contain the full name and include at least 2 fields. |
57 base::android::ScopedJavaLocalRef<jobjectArray> GetProfileLabelsForSettings( | 57 base::android::ScopedJavaLocalRef<jobjectArray> GetProfileLabelsForSettings( |
58 JNIEnv* env, | 58 JNIEnv* env, |
59 const base::android::JavaParamRef<jobject>& unused_obj); | 59 const base::android::JavaParamRef<jobject>& unused_obj); |
60 | 60 |
61 // Gets the labels for the profiles to suggest to the user. These labels are | 61 // Gets the labels for the profiles to suggest to the user. These labels are |
62 // useful for distinguishing the profiles from one another. | 62 // useful for distinguishing the profiles from one another. |
63 // | 63 // |
64 // The labels never contain the full name or email address. All other fields | 64 // The labels never contain the full name, email address, or phone numbers. |
65 // are included in the label. | 65 // All other fields are included in the label. |
66 base::android::ScopedJavaLocalRef<jobjectArray> GetProfileLabelsToSuggest( | 66 base::android::ScopedJavaLocalRef<jobjectArray> GetProfileLabelsToSuggest( |
67 JNIEnv* env, | 67 JNIEnv* env, |
68 const base::android::JavaParamRef<jobject>& unused_obj); | 68 const base::android::JavaParamRef<jobject>& unused_obj); |
69 | 69 |
70 // Returns the label of the given profile for PaymentRequest. This label does | 70 // Returns the label of the given profile for PaymentRequest. This label does |
71 // not contain the full name or the email address. All other fields are | 71 // not contain the full name or the email address. All other fields are |
72 // included in the label. | 72 // included in the label. |
73 base::android::ScopedJavaLocalRef<jstring> GetAddressLabelForPaymentRequest( | 73 base::android::ScopedJavaLocalRef<jstring> GetAddressLabelForPaymentRequest( |
74 JNIEnv* env, | 74 JNIEnv* env, |
75 const base::android::JavaParamRef<jobject>& unused_obj, | 75 const base::android::JavaParamRef<jobject>& unused_obj, |
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
214 // Returns the GUIDs of the |credit_cards| passed as parameter. | 214 // Returns the GUIDs of the |credit_cards| passed as parameter. |
215 base::android::ScopedJavaLocalRef<jobjectArray> GetCreditCardGUIDs( | 215 base::android::ScopedJavaLocalRef<jobjectArray> GetCreditCardGUIDs( |
216 JNIEnv* env, | 216 JNIEnv* env, |
217 const std::vector<CreditCard*>& credit_cards); | 217 const std::vector<CreditCard*>& credit_cards); |
218 | 218 |
219 // Gets the labels for the |profiles| passed as parameters. These labels are | 219 // Gets the labels for the |profiles| passed as parameters. These labels are |
220 // useful for distinguishing the profiles from one another. | 220 // useful for distinguishing the profiles from one another. |
221 // | 221 // |
222 // The labels never contain the full name and include at least 2 fields. | 222 // The labels never contain the full name and include at least 2 fields. |
223 // | 223 // |
224 // If |address_only| is true, then such fields as phone number and email | 224 // If |address_only| is true, then such fields as phone number, and email |
225 // address are also omitted, but all fields are included in the label. | 225 // address are also omitted, but all other fields are included in the label. |
226 base::android::ScopedJavaLocalRef<jobjectArray> GetProfileLabels( | 226 base::android::ScopedJavaLocalRef<jobjectArray> GetProfileLabels( |
227 JNIEnv* env, | 227 JNIEnv* env, |
228 bool address_only, | 228 bool address_only, |
229 std::vector<AutofillProfile*> profiles); | 229 std::vector<AutofillProfile*> profiles); |
230 | 230 |
231 // Pointer to the java counterpart. | 231 // Pointer to the java counterpart. |
232 JavaObjectWeakGlobalRef weak_java_obj_; | 232 JavaObjectWeakGlobalRef weak_java_obj_; |
233 | 233 |
234 // Pointer to the PersonalDataManager for the main profile. | 234 // Pointer to the PersonalDataManager for the main profile. |
235 PersonalDataManager* personal_data_manager_; | 235 PersonalDataManager* personal_data_manager_; |
236 | 236 |
237 DISALLOW_COPY_AND_ASSIGN(PersonalDataManagerAndroid); | 237 DISALLOW_COPY_AND_ASSIGN(PersonalDataManagerAndroid); |
238 }; | 238 }; |
239 | 239 |
240 } // namespace autofill | 240 } // namespace autofill |
241 | 241 |
242 #endif // CHROME_BROWSER_AUTOFILL_ANDROID_PERSONAL_DATA_MANAGER_ANDROID_H_ | 242 #endif // CHROME_BROWSER_AUTOFILL_ANDROID_PERSONAL_DATA_MANAGER_ANDROID_H_ |
OLD | NEW |