SetupIntentPatterns extension

Adds pattern-matching-related methods to SetupIntent.

on

Methods

map<TResult extends Object?>(TResult $default(_SetupIntent value)) → TResult

Available on SetupIntent, provided by the SetupIntentPatterns extension

A switch-like method, using callbacks.
mapOrNull<TResult extends Object?>(TResult? $default(_SetupIntent value)?) → TResult?

Available on SetupIntent, provided by the SetupIntentPatterns extension

A variant of map that fallback to returning null.
maybeMap<TResult extends Object?>(TResult $default(_SetupIntent value)?, {required TResult orElse()}) → TResult

Available on SetupIntent, provided by the SetupIntentPatterns extension

A variant of map that fallback to returning orElse.
maybeWhen<TResult extends Object?>(TResult $default(String id, String object, String? application, String? attachToSelf, SetupIntentCancellationReason? cancellationReason, String clientSecret, int? created, String? customer, String? description, List<SetupIntentFlowDirections>? flowDirections, dynamic lastSetupError, String? latestAttempt, bool livemode, String? mandate, Map<String, dynamic> metadata, dynamic nextAction, String? onBehalfOf, String? paymentMethod, dynamic paymentMethodOptions, List<PaymentMethodType> paymentMethodTypes, String? singleUseMandate, SetupIntentsStatus status, SetupIntentUsage usage)?, {required TResult orElse()}) → TResult

Available on SetupIntent, provided by the SetupIntentPatterns extension

A variant of when that fallback to an orElse callback.
when<TResult extends Object?>(TResult $default(String id, String object, String? application, String? attachToSelf, SetupIntentCancellationReason? cancellationReason, String clientSecret, int? created, String? customer, String? description, List<SetupIntentFlowDirections>? flowDirections, dynamic lastSetupError, String? latestAttempt, bool livemode, String? mandate, Map<String, dynamic> metadata, dynamic nextAction, String? onBehalfOf, String? paymentMethod, dynamic paymentMethodOptions, List<PaymentMethodType> paymentMethodTypes, String? singleUseMandate, SetupIntentsStatus status, SetupIntentUsage usage)) → TResult

Available on SetupIntent, provided by the SetupIntentPatterns extension

A switch-like method, using callbacks.
whenOrNull<TResult extends Object?>(TResult? $default(String id, String object, String? application, String? attachToSelf, SetupIntentCancellationReason? cancellationReason, String clientSecret, int? created, String? customer, String? description, List<SetupIntentFlowDirections>? flowDirections, dynamic lastSetupError, String? latestAttempt, bool livemode, String? mandate, Map<String, dynamic> metadata, dynamic nextAction, String? onBehalfOf, String? paymentMethod, dynamic paymentMethodOptions, List<PaymentMethodType> paymentMethodTypes, String? singleUseMandate, SetupIntentsStatus status, SetupIntentUsage usage)?) → TResult?

Available on SetupIntent, provided by the SetupIntentPatterns extension

A variant of when that fallback to returning null