| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_PHONE_FIELD_H_ | 5 #ifndef CHROME_BROWSER_AUTOFILL_PHONE_FIELD_H_ |
| 6 #define CHROME_BROWSER_AUTOFILL_PHONE_FIELD_H_ | 6 #define CHROME_BROWSER_AUTOFILL_PHONE_FIELD_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| 11 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
| 12 #include "base/memory/scoped_ptr.h" | |
| 13 #include "chrome/browser/autofill/autofill_type.h" | 12 #include "chrome/browser/autofill/autofill_type.h" |
| 14 #include "chrome/browser/autofill/form_field.h" | 13 #include "chrome/browser/autofill/form_field.h" |
| 15 #include "chrome/browser/autofill/phone_number.h" | 14 #include "chrome/browser/autofill/phone_number.h" |
| 16 | 15 |
| 17 class AutofillField; | 16 class AutofillField; |
| 18 class AutofillScanner; | 17 class AutofillScanner; |
| 19 | 18 |
| 20 // A phone number in one of the following formats: | 19 // A phone number in one of the following formats: |
| 21 // - area code, prefix, suffix | 20 // - area code, prefix, suffix |
| 22 // - area code, number | 21 // - area code, number |
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 86 static struct Parser { | 85 static struct Parser { |
| 87 RegexType regex; // Field matching reg-ex. | 86 RegexType regex; // Field matching reg-ex. |
| 88 PhonePart phone_part; // Index of the field. | 87 PhonePart phone_part; // Index of the field. |
| 89 size_t max_size; // Max size of the field to match. 0 means any. | 88 size_t max_size; // Max size of the field to match. 0 means any. |
| 90 } phone_field_grammars_[]; | 89 } phone_field_grammars_[]; |
| 91 | 90 |
| 92 DISALLOW_COPY_AND_ASSIGN(PhoneField); | 91 DISALLOW_COPY_AND_ASSIGN(PhoneField); |
| 93 }; | 92 }; |
| 94 | 93 |
| 95 #endif // CHROME_BROWSER_AUTOFILL_PHONE_FIELD_H_ | 94 #endif // CHROME_BROWSER_AUTOFILL_PHONE_FIELD_H_ |
| OLD | NEW |