encode<V> static method
Implementation
static V encode<V>(
PaymentMethodOptionsSofort instance,
Encoder<V> encoder,
) {
final container = encoder.container<String>();
if (instance.preferredLanguage != null) {
PaymentMethodDetailsSofortPreferredLanguage.encode(
instance.preferredLanguage!,
container.nestedSingleValueContainer('preferred_language').encoder,
);
}
if (instance.setupFutureUsage != null) {
CheckoutLinkPaymentMethodOptionsSetupFutureUsage.encode(
instance.setupFutureUsage!,
container.nestedSingleValueContainer('setup_future_usage').encoder,
);
}
return container.value;
}