encode<V> static method

V encode<V>(
  1. InvoicePaymentMethodOptionsCard instance,
  2. Encoder<V> encoder
)

Implementation

static V encode<V>(
  InvoicePaymentMethodOptionsCard instance,
  Encoder<V> encoder,
) {
  final container = encoder.container<String>();
  if (instance.installments != null) {
    InvoiceInstallmentsCard.encode(
      instance.installments!,
      container.nestedSingleValueContainer('installments').encoder,
    );
  }
  if (instance.requestThreeDSecure != null) {
    container.encodeString(
      'request_three_d_secure',
      instance.requestThreeDSecure!,
    );
  }
  return container.value;
}