blob: 6803a6d591a734c97a2953a32e28b2b9f9c25ae0 [file] [log] [blame]
Avi Drissman8ba1bad2022-09-13 19:22:361// Copyright 2017 The Chromium Authors
tmartino9c32cf82017-04-04 20:34:392// 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_PAYMENTS_CORE_STRINGS_UTIL_H_
6#define COMPONENTS_PAYMENTS_CORE_STRINGS_UTIL_H_
7
Rouslan Solomakhin25d708b2017-06-23 17:12:038#include <set>
Rouslan Solomakhin33a338b492017-05-23 16:02:549#include <string>
10
Marc-Antoine Courteau8ede7312017-10-16 16:08:4011#include "build/build_config.h"
Florian Leimgruber9c6a9a1f2025-02-27 15:09:1312#include "components/autofill/core/browser/data_model/payments/credit_card.h"
tmartino9c32cf82017-04-04 20:34:3913#include "components/payments/core/payment_options_provider.h"
14
Rouslan Solomakhin33a338b492017-05-23 16:02:5415namespace autofill {
16class AutofillProfile;
17}
18
tmartino9c32cf82017-04-04 20:34:3919namespace payments {
20
Rouslan Solomakhin33a338b492017-05-23 16:02:5421// Helper function to create a shipping address label from an autofill profile.
Jan Wilken Dörriefa241ba2021-03-11 17:57:0122std::u16string GetShippingAddressLabelFromAutofillProfile(
Rouslan Solomakhin33a338b492017-05-23 16:02:5423 const autofill::AutofillProfile& profile,
24 const std::string& locale);
25
mahmadi747b4702017-04-11 12:34:1826// Gets the informational message to be displayed in the shipping address
27// selector view when there are no valid shipping options.
Jan Wilken Dörriefa241ba2021-03-11 17:57:0128std::u16string GetShippingAddressSelectorInfoMessage(
mahmadi747b4702017-04-11 12:34:1829 PaymentShippingType shipping_type);
30
tmartino9c32cf82017-04-04 20:34:3931// Gets the appropriate display string for the Shipping Address string for the
32// given PaymentShippingType.
Jan Wilken Dörriefa241ba2021-03-11 17:57:0133std::u16string GetShippingAddressSectionString(
tmartino9c32cf82017-04-04 20:34:3934 PaymentShippingType shipping_type);
35
36// Gets the appropriate display string for the Shipping Option string for the
37// given PaymentShippingType.
Jan Wilken Dörriefa241ba2021-03-11 17:57:0138std::u16string GetShippingOptionSectionString(
tmartino9c32cf82017-04-04 20:34:3939 PaymentShippingType shipping_type);
40
tmartino9c32cf82017-04-04 20:34:3941} // namespace payments
42
43#endif // COMPONENTS_PAYMENTS_CORE_STRINGS_UTIL_H_