Skip to content
This repository has been archived by the owner on Oct 19, 2024. It is now read-only.

MoneyEncodingOptions

mattt edited this page May 6, 2020 · 1 revision

MoneyEncodingOptions

Custom encoding options for Money values.

public struct MoneyEncodingOptions: OptionSet

Configure the encoding behavior either by using the JSONDecoder.moneyEncodingOptions property or by setting the CodingUserInfoKey.moneyEncodingOptions key in the encoder's userInfo property.

Inheritance

OptionSet

Initializers

init(rawValue:)

public init(rawValue: Int)

Properties

rawValue

let rawValue: Int

omitCurrency

Encodes the Money value as a single value, without specifying a currency.

let omitCurrency

encodeAmountAsString

Encodes the string representation of amount instead of the built-in Decimal encoding.

let encodeAmountAsString
Clone this wiki locally