copyWithWrapped method

InvestmentTransaction copyWithWrapped({
  1. Wrapped<String>? investmentTransactionId,
  2. Wrapped<String?>? cancelTransactionId,
  3. Wrapped<String>? accountId,
  4. Wrapped<String?>? securityId,
  5. Wrapped<DateTime>? date,
  6. Wrapped<String>? name,
  7. Wrapped<double>? quantity,
  8. Wrapped<double>? amount,
  9. Wrapped<double>? price,
  10. Wrapped<double?>? fees,
  11. Wrapped<InvestmentTransactionType>? type,
  12. Wrapped<InvestmentTransactionSubtype>? subtype,
  13. Wrapped<String?>? isoCurrencyCode,
  14. Wrapped<String?>? unofficialCurrencyCode,
})

Implementation

InvestmentTransaction copyWithWrapped(
    {Wrapped<String>? investmentTransactionId,
    Wrapped<String?>? cancelTransactionId,
    Wrapped<String>? accountId,
    Wrapped<String?>? securityId,
    Wrapped<DateTime>? date,
    Wrapped<String>? name,
    Wrapped<double>? quantity,
    Wrapped<double>? amount,
    Wrapped<double>? price,
    Wrapped<double?>? fees,
    Wrapped<enums.InvestmentTransactionType>? type,
    Wrapped<enums.InvestmentTransactionSubtype>? subtype,
    Wrapped<String?>? isoCurrencyCode,
    Wrapped<String?>? unofficialCurrencyCode}) {
  return InvestmentTransaction(
      investmentTransactionId: (investmentTransactionId != null
          ? investmentTransactionId.value
          : this.investmentTransactionId),
      cancelTransactionId: (cancelTransactionId != null
          ? cancelTransactionId.value
          : this.cancelTransactionId),
      accountId: (accountId != null ? accountId.value : this.accountId),
      securityId: (securityId != null ? securityId.value : this.securityId),
      date: (date != null ? date.value : this.date),
      name: (name != null ? name.value : this.name),
      quantity: (quantity != null ? quantity.value : this.quantity),
      amount: (amount != null ? amount.value : this.amount),
      price: (price != null ? price.value : this.price),
      fees: (fees != null ? fees.value : this.fees),
      type: (type != null ? type.value : this.type),
      subtype: (subtype != null ? subtype.value : this.subtype),
      isoCurrencyCode: (isoCurrencyCode != null
          ? isoCurrencyCode.value
          : this.isoCurrencyCode),
      unofficialCurrencyCode: (unofficialCurrencyCode != null
          ? unofficialCurrencyCode.value
          : this.unofficialCurrencyCode));
}