@@ -6345,6 +6345,7 @@ private constructor(
63456345 class Transaction
63466346 private constructor (
63476347 private val amount: JsonField <Double >,
6348+ private val cardholderAmount: JsonField <Double >,
63486349 private val currency: JsonField <String >,
63496350 private val currencyExponent: JsonField <Double >,
63506351 private val dateTime: JsonField <OffsetDateTime >,
@@ -6355,6 +6356,9 @@ private constructor(
63556356 @JsonCreator
63566357 private constructor (
63576358 @JsonProperty(" amount" ) @ExcludeMissing amount: JsonField <Double > = JsonMissing .of(),
6359+ @JsonProperty(" cardholder_amount" )
6360+ @ExcludeMissing
6361+ cardholderAmount: JsonField <Double > = JsonMissing .of(),
63586362 @JsonProperty(" currency" )
63596363 @ExcludeMissing
63606364 currency: JsonField <String > = JsonMissing .of(),
@@ -6365,7 +6369,15 @@ private constructor(
63656369 @ExcludeMissing
63666370 dateTime: JsonField <OffsetDateTime > = JsonMissing .of(),
63676371 @JsonProperty(" type" ) @ExcludeMissing type: JsonField <Type > = JsonMissing .of(),
6368- ) : this (amount, currency, currencyExponent, dateTime, type, mutableMapOf ())
6372+ ) : this (
6373+ amount,
6374+ cardholderAmount,
6375+ currency,
6376+ currencyExponent,
6377+ dateTime,
6378+ type,
6379+ mutableMapOf (),
6380+ )
63696381
63706382 /* *
63716383 * Amount of the purchase in minor units of currency with all punctuation removed. Maps to
@@ -6376,6 +6388,15 @@ private constructor(
63766388 */
63776389 fun amount (): Double = amount.getRequired(" amount" )
63786390
6391+ /* *
6392+ * Approximate amount of the purchase in minor units of cardholder currency. Derived from
6393+ * `amount` using a daily conversion rate.
6394+ *
6395+ * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
6396+ * server responded with an unexpected value).
6397+ */
6398+ fun cardholderAmount (): Optional <Double > = cardholderAmount.getOptional(" cardholder_amount" )
6399+
63796400 /* *
63806401 * Currency of the purchase. Maps to EMV 3DS field purchaseCurrency.
63816402 *
@@ -6418,6 +6439,16 @@ private constructor(
64186439 */
64196440 @JsonProperty(" amount" ) @ExcludeMissing fun _amount (): JsonField <Double > = amount
64206441
6442+ /* *
6443+ * Returns the raw JSON value of [cardholderAmount].
6444+ *
6445+ * Unlike [cardholderAmount], this method doesn't throw if the JSON field has an unexpected
6446+ * type.
6447+ */
6448+ @JsonProperty(" cardholder_amount" )
6449+ @ExcludeMissing
6450+ fun _cardholderAmount (): JsonField <Double > = cardholderAmount
6451+
64216452 /* *
64226453 * Returns the raw JSON value of [currency].
64236454 *
@@ -6471,6 +6502,7 @@ private constructor(
64716502 * The following fields are required:
64726503 * ```java
64736504 * .amount()
6505+ * .cardholderAmount()
64746506 * .currency()
64756507 * .currencyExponent()
64766508 * .dateTime()
@@ -6484,6 +6516,7 @@ private constructor(
64846516 class Builder internal constructor() {
64856517
64866518 private var amount: JsonField <Double >? = null
6519+ private var cardholderAmount: JsonField <Double >? = null
64876520 private var currency: JsonField <String >? = null
64886521 private var currencyExponent: JsonField <Double >? = null
64896522 private var dateTime: JsonField <OffsetDateTime >? = null
@@ -6493,6 +6526,7 @@ private constructor(
64936526 @JvmSynthetic
64946527 internal fun from (transaction : Transaction ) = apply {
64956528 amount = transaction.amount
6529+ cardholderAmount = transaction.cardholderAmount
64966530 currency = transaction.currency
64976531 currencyExponent = transaction.currencyExponent
64986532 dateTime = transaction.dateTime
@@ -6515,6 +6549,38 @@ private constructor(
65156549 */
65166550 fun amount (amount : JsonField <Double >) = apply { this .amount = amount }
65176551
6552+ /* *
6553+ * Approximate amount of the purchase in minor units of cardholder currency. Derived
6554+ * from `amount` using a daily conversion rate.
6555+ */
6556+ fun cardholderAmount (cardholderAmount : Double? ) =
6557+ cardholderAmount(JsonField .ofNullable(cardholderAmount))
6558+
6559+ /* *
6560+ * Alias for [Builder.cardholderAmount].
6561+ *
6562+ * This unboxed primitive overload exists for backwards compatibility.
6563+ */
6564+ fun cardholderAmount (cardholderAmount : Double ) =
6565+ cardholderAmount(cardholderAmount as Double? )
6566+
6567+ /* *
6568+ * Alias for calling [Builder.cardholderAmount] with `cardholderAmount.orElse(null)`.
6569+ */
6570+ fun cardholderAmount (cardholderAmount : Optional <Double >) =
6571+ cardholderAmount(cardholderAmount.getOrNull())
6572+
6573+ /* *
6574+ * Sets [Builder.cardholderAmount] to an arbitrary JSON value.
6575+ *
6576+ * You should usually call [Builder.cardholderAmount] with a well-typed [Double] value
6577+ * instead. This method is primarily for setting the field to an undocumented or not yet
6578+ * supported value.
6579+ */
6580+ fun cardholderAmount (cardholderAmount : JsonField <Double >) = apply {
6581+ this .cardholderAmount = cardholderAmount
6582+ }
6583+
65186584 /* * Currency of the purchase. Maps to EMV 3DS field purchaseCurrency. */
65196585 fun currency (currency : String ) = currency(JsonField .of(currency))
65206586
@@ -6605,6 +6671,7 @@ private constructor(
66056671 * The following fields are required:
66066672 * ```java
66076673 * .amount()
6674+ * .cardholderAmount()
66086675 * .currency()
66096676 * .currencyExponent()
66106677 * .dateTime()
@@ -6616,6 +6683,7 @@ private constructor(
66166683 fun build (): Transaction =
66176684 Transaction (
66186685 checkRequired(" amount" , amount),
6686+ checkRequired(" cardholderAmount" , cardholderAmount),
66196687 checkRequired(" currency" , currency),
66206688 checkRequired(" currencyExponent" , currencyExponent),
66216689 checkRequired(" dateTime" , dateTime),
@@ -6632,6 +6700,7 @@ private constructor(
66326700 }
66336701
66346702 amount()
6703+ cardholderAmount()
66356704 currency()
66366705 currencyExponent()
66376706 dateTime()
@@ -6656,6 +6725,7 @@ private constructor(
66566725 @JvmSynthetic
66576726 internal fun validity (): Int =
66586727 (if (amount.asKnown().isPresent) 1 else 0 ) +
6728+ (if (cardholderAmount.asKnown().isPresent) 1 else 0 ) +
66596729 (if (currency.asKnown().isPresent) 1 else 0 ) +
66606730 (if (currencyExponent.asKnown().isPresent) 1 else 0 ) +
66616731 (if (dateTime.asKnown().isPresent) 1 else 0 ) +
@@ -6815,17 +6885,17 @@ private constructor(
68156885 return true
68166886 }
68176887
6818- return /* spotless:off */ other is Transaction && amount == other.amount && currency == other.currency && currencyExponent == other.currencyExponent && dateTime == other.dateTime && type == other.type && additionalProperties == other.additionalProperties /* spotless:on */
6888+ return /* spotless:off */ other is Transaction && amount == other.amount && cardholderAmount == other.cardholderAmount && currency == other.currency && currencyExponent == other.currencyExponent && dateTime == other.dateTime && type == other.type && additionalProperties == other.additionalProperties /* spotless:on */
68196889 }
68206890
68216891 /* spotless:off */
6822- private val hashCode: Int by lazy { Objects .hash(amount, currency, currencyExponent, dateTime, type, additionalProperties) }
6892+ private val hashCode: Int by lazy { Objects .hash(amount, cardholderAmount, currency, currencyExponent, dateTime, type, additionalProperties) }
68236893 /* spotless:on */
68246894
68256895 override fun hashCode (): Int = hashCode
68266896
68276897 override fun toString () =
6828- " Transaction{amount=$amount , currency=$currency , currencyExponent=$currencyExponent , dateTime=$dateTime , type=$type , additionalProperties=$additionalProperties }"
6898+ " Transaction{amount=$amount , cardholderAmount= $cardholderAmount , currency=$currency , currencyExponent=$currencyExponent , dateTime=$dateTime , type=$type , additionalProperties=$additionalProperties }"
68296899 }
68306900
68316901 override fun equals (other : Any? ): Boolean {
0 commit comments