address_i18n.h revision cedac228d2dd51db4b79ea1e72c7f249408ee061
1// Copyright 2014 The Chromium Authors. All rights reserved. 2// Use of this source code is governed by a BSD-style license that can be 3// found in the LICENSE file. 4 5#ifndef COMPONENTS_AUTOFILL_CORE_BROWSER_ADDRESS_I18N_H_ 6#define COMPONENTS_AUTOFILL_CORE_BROWSER_ADDRESS_I18N_H_ 7 8#include "base/callback_forward.h" 9#include "base/memory/scoped_ptr.h" 10#include "base/strings/string16.h" 11 12namespace i18n { 13namespace addressinput { 14struct AddressData; 15} 16} 17 18namespace autofill { 19 20class AutofillProfile; 21class AutofillType; 22 23namespace i18n { 24 25// Creates an AddressData object for internationalized address display or 26// validation using |get_info| for field values. 27scoped_ptr< ::i18n::addressinput::AddressData> CreateAddressData( 28 const base::Callback<base::string16(const AutofillType&)>& get_info); 29 30// Creates an |AddressData| from |profile|. 31scoped_ptr< ::i18n::addressinput::AddressData> 32 CreateAddressDataFromAutofillProfile(const AutofillProfile& profile, 33 const std::string& app_locale); 34 35} // namespace i18n 36} // namespace autofill 37 38#endif // COMPONENTS_AUTOFILL_CORE_BROWSER_ADDRESS_I18N_H_ 39