Order class abstract

The order

Available extensions
Annotations
  • @freezed

Constructors

Order({required String id, required String email, required String currencyCode, required String customerUrl, required LineItemsOrder lineItems, required String name, required int orderNumber, required String processedAt, required ShippingAddress? shippingAddress, required ShippingAddress? billingAddress, required String statusUrl, required PriceV2 subtotalPriceV2, required PriceV2 totalPriceV2, required PriceV2 totalShippingPriceV2, required PriceV2 totalTaxV2, required String financialStatus, required String fulfillmentStatus, PriceV2? totalRefundedV2, String? phone, String? cursor, String? canceledAt, String? cancelReason, List<SuccessfulFullfilment>? successfulFulfillments})
The order constructor
const
factory
Order.fromGraphJson(Map<String, dynamic> json)
The order from graph json
factory
Order.fromJson(Map<String, dynamic> json)
The order from json
factory

Properties

billingAddress ShippingAddress?
no setterinherited
canceledAt String?
no setterinherited
cancelReason String?
no setterinherited
copyWith → $OrderCopyWith<Order>
Create a copy of Order with the given fields replaced by the non-null parameter values.
no setterinherited
currencyCode String
no setterinherited
cursor String?
no setterinherited
customerUrl String
no setterinherited
email String
no setterinherited
financialStatus String
no setterinherited
fulfillmentStatus String
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
id String
no setterinherited
lineItems LineItemsOrder
no setterinherited
name String
no setterinherited
orderNumber int
no setterinherited
phone String?
no setterinherited
processedAt String
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
shippingAddress ShippingAddress?
no setterinherited
statusUrl String
no setterinherited
subtotalPriceV2 PriceV2
no setterinherited
successfulFulfillments List<SuccessfulFullfilment>?
no setterinherited
totalPriceV2 PriceV2
no setterinherited
totalRefundedV2 PriceV2?
no setterinherited
totalShippingPriceV2 PriceV2
no setterinherited
totalTaxV2 PriceV2
no setterinherited

Methods

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

Available on Order, provided by the OrderPatterns extension

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

Available on Order, provided by the OrderPatterns extension

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

Available on Order, provided by the OrderPatterns extension

A variant of map that fallback to returning orElse.
maybeWhen<TResult extends Object?>(TResult $default(String id, String email, String currencyCode, String customerUrl, LineItemsOrder lineItems, String name, int orderNumber, String processedAt, ShippingAddress? shippingAddress, ShippingAddress? billingAddress, String statusUrl, PriceV2 subtotalPriceV2, PriceV2 totalPriceV2, PriceV2 totalShippingPriceV2, PriceV2 totalTaxV2, String financialStatus, String fulfillmentStatus, PriceV2? totalRefundedV2, String? phone, String? cursor, String? canceledAt, String? cancelReason, List<SuccessfulFullfilment>? successfulFulfillments)?, {required TResult orElse()}) → TResult

Available on Order, provided by the OrderPatterns 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 Order to a JSON map.
inherited
toString() String
A string representation of this object.
inherited
when<TResult extends Object?>(TResult $default(String id, String email, String currencyCode, String customerUrl, LineItemsOrder lineItems, String name, int orderNumber, String processedAt, ShippingAddress? shippingAddress, ShippingAddress? billingAddress, String statusUrl, PriceV2 subtotalPriceV2, PriceV2 totalPriceV2, PriceV2 totalShippingPriceV2, PriceV2 totalTaxV2, String financialStatus, String fulfillmentStatus, PriceV2? totalRefundedV2, String? phone, String? cursor, String? canceledAt, String? cancelReason, List<SuccessfulFullfilment>? successfulFulfillments)) → TResult

Available on Order, provided by the OrderPatterns extension

A switch-like method, using callbacks.
whenOrNull<TResult extends Object?>(TResult? $default(String id, String email, String currencyCode, String customerUrl, LineItemsOrder lineItems, String name, int orderNumber, String processedAt, ShippingAddress? shippingAddress, ShippingAddress? billingAddress, String statusUrl, PriceV2 subtotalPriceV2, PriceV2 totalPriceV2, PriceV2 totalShippingPriceV2, PriceV2 totalTaxV2, String financialStatus, String fulfillmentStatus, PriceV2? totalRefundedV2, String? phone, String? cursor, String? canceledAt, String? cancelReason, List<SuccessfulFullfilment>? successfulFulfillments)?) → TResult?

Available on Order, provided by the OrderPatterns extension

A variant of when that fallback to returning null

Operators

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