encode<V> static method

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

Implementation

static V encode<V>(
  BankConnectionsResourceBalanceRefresh instance,
  Encoder<V> encoder,
) {
  final container = encoder.container<String>();
  container.encodeDateTime(
    'last_attempted_at',
    instance.lastAttemptedAt,
  );
  if (instance.nextRefreshAvailableAt != null) {
    container.encodeDateTime(
      'next_refresh_available_at',
      instance.nextRefreshAvailableAt!,
    );
  }
  container.encodeString(
    'status',
    instance.status,
  );
  return container.value;
}