LocalePreferences
public struct LocalePreferences : Codable
extension LocalePreferences: Equatable
Preferences about the customer’s country-of-residence (COR), display currency and preferred language
-
The two-character ISO code for the country of residence of the customer - e.g. “IE”
Declaration
Swift
public let countryOfResidence: String
-
The three-character currency code for the customer’s preferred display currency - e.g. “EUR”
Declaration
Swift
public let displayCurrency: String
-
The two-character language code for the customer’s preferred language - e.g. “EN”
Declaration
Swift
public let preferredLanguage: String
-
Initializes the locale preferences with specified COR, currency and language
Declaration
Swift
public init(countryOfResidence: String, displayCurrency: String, preferredLanguage: String)
Parameters
countryOfResidence
The customer’s country of residence (COR)
displayCurrency
The currency to use when displaying product pricing
preferredLanguage
The customer’s preferred presentation language
-
Test whether two locale preferences are equivalent Parameters: - lhs: The first locale preferences to compare - rhs: The second locale preferences to compare
Declaration
Swift
public static func == (lhs: LocalePreferences, rhs: LocalePreferences) -> Bool