copyWith method

  1. @override
Items copyWith({
  1. String? name,
  2. int? quantity,
  3. int? amount,
  4. int? price,
  5. PaymentMethod? paymentMethod,
  6. PaymentObject? paymentObject,
  7. Tax? tax,
  8. AgentData? agentData,
  9. SupplierInfo? supplierInfo,
  10. String? ean13,
  11. String? shopCode,
  12. String? userData,
  13. int? excise,
  14. String? countryCode,
  15. String? declarationNumber,
  16. String? measurementUnit,
  17. String? markProcessingMode,
  18. MarkCode? markCode,
  19. MarkQuantity? markQuantity,
  20. List<SectoralItemProps>? sectoralItemProps,
})
override

Создает экземпляр с заданными параметрами

Implementation

@override
Items copyWith({
  String? name,
  int? quantity,
  int? amount,
  int? price,
  PaymentMethod? paymentMethod,
  PaymentObject? paymentObject,
  Tax? tax,
  AgentData? agentData,
  SupplierInfo? supplierInfo,
  String? ean13,
  String? shopCode,
  String? userData,
  int? excise,
  String? countryCode,
  String? declarationNumber,
  String? measurementUnit,
  String? markProcessingMode,
  MarkCode? markCode,
  MarkQuantity? markQuantity,
  List<SectoralItemProps>? sectoralItemProps,
}) {
  return Items.all(
    name: name ?? this.name,
    quantity: quantity ?? this.quantity,
    amount: amount ?? this.amount,
    price: price ?? this.price,
    paymentMethod: paymentMethod ?? this.paymentMethod,
    paymentObject: paymentObject ?? this.paymentObject,
    tax: tax ?? this.tax,
    agentData: agentData ?? this.agentData,
    supplierInfo: supplierInfo ?? this.supplierInfo,
    ean13: ean13 ?? this.ean13,
    shopCode: shopCode ?? this.shopCode,
    userData: userData ?? this.userData,
    excise: excise ?? this.excise,
    countryCode: countryCode ?? this.countryCode,
    declarationNumber: declarationNumber ?? this.declarationNumber,
    measurementUnit: measurementUnit ?? this.measurementUnit,
    markProcessingMode: markProcessingMode ?? this.markProcessingMode,
    markCode: markCode ?? this.markCode,
    markQuantity: markQuantity ?? this.markQuantity,
    sectoralItemProps: sectoralItemProps ?? this.sectoralItemProps,
  );
}