encode<V> static method
Implementation
static V encode<V>(
InvoiceThresholdReason instance,
Encoder<V> encoder,
) {
final container = encoder.container<String>();
if (instance.amountGte != null) {
container.encodeInt(
'amount_gte',
instance.amountGte!,
);
}
container.encodeList(
'item_reasons',
(container) => instance.itemReasons
.forEach((el) => InvoiceItemThresholdReason.encode(
el,
container.nestedSingleValueContainer().encoder,
)),
);
return container.value;
}