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

Side by Side Diff: chrome/browser/autofill/form_group.h

Issue 6650014: Autofill extend profiles to include multi-valued fields, part 2. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Nit Created 9 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « chrome/browser/autofill/fax_number.cc ('k') | chrome/browser/autofill/home_phone_number.h » ('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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_FORM_GROUP_H_ 5 #ifndef CHROME_BROWSER_AUTOFILL_FORM_GROUP_H_
6 #define CHROME_BROWSER_AUTOFILL_FORM_GROUP_H_ 6 #define CHROME_BROWSER_AUTOFILL_FORM_GROUP_H_
7 #pragma once 7 #pragma once
8 8
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/string16.h" 11 #include "base/string16.h"
12 #include "base/string_util.h" 12 #include "base/string_util.h"
13 #include "chrome/browser/autofill/autofill_type.h" 13 #include "chrome/browser/autofill/autofill_type.h"
14 #include "chrome/browser/autofill/field_types.h" 14 #include "chrome/browser/autofill/field_types.h"
15 15
16 // This class is an interface for collections of form fields, grouped by type. 16 // This class is an interface for collections of form fields, grouped by type.
17 // The information in objects of this class is managed by the 17 // The information in objects of this class is managed by the
18 // PersonalDataManager. 18 // PersonalDataManager.
19 class FormGroup { 19 class FormGroup {
20 public: 20 public:
21 virtual ~FormGroup() {} 21 virtual ~FormGroup() {}
22 22
23 // Returns a clone of this object.
24 virtual FormGroup* Clone() const = 0;
25
26 // Used to determine the type of a field based on the text that a user enters 23 // Used to determine the type of a field based on the text that a user enters
27 // into the field. The field types can then be reported back to the server. 24 // into the field. The field types can then be reported back to the server.
28 // This method is additive on |possible_types|. 25 // This method is additive on |possible_types|.
29 virtual void GetPossibleFieldTypes(const string16& text, 26 virtual void GetPossibleFieldTypes(const string16& text,
30 FieldTypeSet* possible_types) const = 0; 27 FieldTypeSet* possible_types) const = 0;
31 28
32 // Returns a set of AutofillFieldTypes for which this FormGroup has non-empty 29 // Returns a set of AutofillFieldTypes for which this FormGroup has non-empty
33 // data. 30 // data.
34 virtual void GetAvailableFieldTypes(FieldTypeSet* available_types) const = 0; 31 virtual void GetAvailableFieldTypes(FieldTypeSet* available_types) const = 0;
35 32
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 bool IntersectionOfTypesHasEqualValues(const FormGroup& form_group) const; 65 bool IntersectionOfTypesHasEqualValues(const FormGroup& form_group) const;
69 66
70 // Merges the field data in |form_group| with this FormGroup. 67 // Merges the field data in |form_group| with this FormGroup.
71 void MergeWith(const FormGroup& form_group); 68 void MergeWith(const FormGroup& form_group);
72 69
73 // Overwrites the field data in |form_group| with this FormGroup. 70 // Overwrites the field data in |form_group| with this FormGroup.
74 void OverwriteWith(const FormGroup& form_group); 71 void OverwriteWith(const FormGroup& form_group);
75 }; 72 };
76 73
77 #endif // CHROME_BROWSER_AUTOFILL_FORM_GROUP_H_ 74 #endif // CHROME_BROWSER_AUTOFILL_FORM_GROUP_H_
OLDNEW
« no previous file with comments | « chrome/browser/autofill/fax_number.cc ('k') | chrome/browser/autofill/home_phone_number.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698