Cart class

Annotations

Constructors

Cart()
Cart.fromJson(Map<String, dynamic> json)
factory

Properties

allItems List<CartItem>
We have three type of items on the cart [...]
@JsonKey(name: 'items'), read / write
allMessages String
@JsonKey(ignore: true), read-only
availableGiftItems List<CartItem>
read / write
bonusAmount double
@JsonKey(defaultValue: 0), read / write
cartItems List<CartItem>
Shorthand property to get only the regular AND promotional items (at the cart we show only those two items)
@JsonKey(ignore: true), read-only
cep String
read / write
changesFromLastUpdate Map<String, dynamic>
The map containing the changes on the lastUpdate [...]
@JsonKey(ignore: true), read / write
cpf String
read / write
cpfInvoice String
read / write
cpfPickUp String
read / write
dealerCode String
read / write
deliveryAddress UserAddress
read / write
deliveryTime int
read / write
discountAmount double
read / write
expirationDate DateTime
The Cart has an expiration date [...]
read-only
feeAmount double
read / write
freight Freight
read / write
freightAmount double
read / write
giftItems List<CartItem>
Shorthand property to get only the gift items
@JsonKey(ignore: true), read-only
giftsQuantityAllowed int
@JsonKey(defaultValue: 0), read / write
hasChanged bool
Some shorthand methods to simplify the check of changesFromLastUpdate for the most used variables
read-only
hasFeeInstallment bool
read / write
hashCode int
The hash code for this object. [...]
read-only, inherited
id String
read / write
installments int
read / write
isCvvValidated bool
read / write
isDelivery bool
read / write
isPickupOnly bool
@JsonKey(defaultValue: false), read / write
items List<CartItem>
@Deprecated('Please use one of the specific items properties or use `allItems` if you really want them all.'), @JsonKey(ignore: true), read-only
justReceivedGift bool
read-only
latitude double
read / write
longitude double
read / write
loriItems List<CartItem>
Shorthand property to get only the regular items
@JsonKey(ignore: true), read-only
maxInstallments int
read / write
messages List<String>
read / write
modality SellerModality
read / write
needsReload bool
read-only
paymentMethod PaymentMethod
read / write
promotionalItems List<CartItem>
Shorthand property to get only the promotional items
@JsonKey(ignore: true), read-only
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
seller Seller
read / write
separatedItems List<CartItem>
Shorthand property to get all separated items
@JsonKey(ignore: true), read-only
subTotalAmount double
read / write
subTotalSeparatedAmount double
read / write
supportedPaymentMethods List<PaymentMethodType>
read / write
supportedPaymentTypes List<PaymentMethodType>
read / write
totalAmount double
read / write
totalSeparatedAmount double
read / write
voucher Voucher
read / write

Methods

fromMap(Map<String, dynamic> map) → void
isUpdatingFrom(Cart cart, {bool forceUpdate = false}) → void
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toJson() Map<String, dynamic>
toMap() Map<String, dynamic>
toString() String
A string representation of this object. [...]
inherited

Operators

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

Static Properties

defaultExpirationDate DateTime
read-only
timeToLive Duration
read-only