OLD | NEW |
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_ADDRESS_FIELD_H_ | 5 #ifndef CHROME_BROWSER_AUTOFILL_ADDRESS_FIELD_H_ |
6 #define CHROME_BROWSER_AUTOFILL_ADDRESS_FIELD_H_ | 6 #define CHROME_BROWSER_AUTOFILL_ADDRESS_FIELD_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
11 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
12 #include "base/gtest_prod_util.h" | 12 #include "base/gtest_prod_util.h" |
13 #include "base/string16.h" | 13 #include "base/string16.h" |
14 #include "chrome/browser/autofill/autofill_type.h" | 14 #include "chrome/browser/autofill/autofill_type.h" |
15 #include "chrome/browser/autofill/form_field.h" | 15 #include "chrome/browser/autofill/form_field.h" |
16 | 16 |
17 class AutofillField; | 17 class AutofillField; |
18 class AutofillScanner; | 18 class AutofillScanner; |
19 | 19 |
20 class AddressField : public FormField { | 20 class AddressField : public FormField { |
21 public: | 21 public: |
22 static FormField* Parse(AutofillScanner* scanner, bool parse_new_field_types); | 22 static FormField* Parse(AutofillScanner* scanner); |
23 | 23 |
24 protected: | 24 protected: |
25 // FormField: | 25 // FormField: |
26 virtual bool ClassifyField(FieldTypeMap* map) const OVERRIDE; | 26 virtual bool ClassifyField(FieldTypeMap* map) const OVERRIDE; |
27 | 27 |
28 private: | 28 private: |
29 enum AddressType { | 29 enum AddressType { |
30 kGenericAddress = 0, | 30 kGenericAddress = 0, |
31 kBillingAddress, | 31 kBillingAddress, |
32 kShippingAddress | 32 kShippingAddress |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
75 const AutofillField* zip_; | 75 const AutofillField* zip_; |
76 const AutofillField* zip4_; // optional ZIP+4; we don't fill this yet | 76 const AutofillField* zip4_; // optional ZIP+4; we don't fill this yet |
77 const AutofillField* country_; // optional | 77 const AutofillField* country_; // optional |
78 | 78 |
79 AddressType type_; | 79 AddressType type_; |
80 | 80 |
81 DISALLOW_COPY_AND_ASSIGN(AddressField); | 81 DISALLOW_COPY_AND_ASSIGN(AddressField); |
82 }; | 82 }; |
83 | 83 |
84 #endif // CHROME_BROWSER_AUTOFILL_ADDRESS_FIELD_H_ | 84 #endif // CHROME_BROWSER_AUTOFILL_ADDRESS_FIELD_H_ |
OLD | NEW |