PaymentMethodOptions class abstract

Data object that holds the payment options for a payment method.

Available extensions
Annotations
  • @freezed

Constructors

PaymentMethodOptions.new({PaymentIntentsFutureUsage? setupFutureUsage, @JsonKey(name: 'setup_future_usage_values') Map<String, IntentFutureUsage>? setupFutureUsageValues})
const
factory
PaymentMethodOptions.fromJson(Map<String, dynamic> json)
factory

Properties

copyWith → $PaymentMethodOptionsCopyWith<PaymentMethodOptions>
Create a copy of PaymentMethodOptions with the given fields replaced by the non-null parameter values.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
setupFutureUsage PaymentIntentsFutureUsage?
Indicates whether or not you want to reuse this method for future payments.
no setterinherited
setupFutureUsageValues Map<String, IntentFutureUsage>?
This is an experimental feature that may be removed at any time A map of payment method types to setup_future_usage value. (e.g. card: 'OffSession')
no setterinherited

Methods

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

Available on PaymentMethodOptions, provided by the PaymentMethodOptionsPatterns extension

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

Available on PaymentMethodOptions, provided by the PaymentMethodOptionsPatterns extension

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

Available on PaymentMethodOptions, provided by the PaymentMethodOptionsPatterns extension

A variant of map that fallback to returning orElse.
maybeWhen<TResult extends Object?>(TResult $default(PaymentIntentsFutureUsage? setupFutureUsage, Map<String, IntentFutureUsage>? setupFutureUsageValues)?, {required TResult orElse()}) → TResult

Available on PaymentMethodOptions, provided by the PaymentMethodOptionsPatterns extension

A variant of when that fallback to an orElse callback.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Serializes this PaymentMethodOptions to a JSON map.
inherited
toString() String
A string representation of this object.
inherited
when<TResult extends Object?>(TResult $default(PaymentIntentsFutureUsage? setupFutureUsage, Map<String, IntentFutureUsage>? setupFutureUsageValues)) → TResult

Available on PaymentMethodOptions, provided by the PaymentMethodOptionsPatterns extension

A switch-like method, using callbacks.
whenOrNull<TResult extends Object?>(TResult? $default(PaymentIntentsFutureUsage? setupFutureUsage, Map<String, IntentFutureUsage>? setupFutureUsageValues)?) → TResult?

Available on PaymentMethodOptions, provided by the PaymentMethodOptionsPatterns extension

A variant of when that fallback to returning null

Operators

operator ==(Object other) bool
The equality operator.
inherited