copyWithWrapped method

DeviceDataDTO copyWithWrapped({
  1. Wrapped<int?>? id,
  2. Wrapped<String?>? serialNumber,
  3. Wrapped<String?>? displayName,
  4. Wrapped<AddressDTO?>? address,
  5. Wrapped<bool?>? hasServiceAgreement,
  6. Wrapped<ConnectionTypeDTO?>? connectionType,
})

Implementation

DeviceDataDTO copyWithWrapped(
    {Wrapped<int?>? id,
    Wrapped<String?>? serialNumber,
    Wrapped<String?>? displayName,
    Wrapped<AddressDTO?>? address,
    Wrapped<bool?>? hasServiceAgreement,
    Wrapped<enums.ConnectionTypeDTO?>? connectionType}) {
  return DeviceDataDTO(
      id: (id != null ? id.value : this.id),
      serialNumber:
          (serialNumber != null ? serialNumber.value : this.serialNumber),
      displayName:
          (displayName != null ? displayName.value : this.displayName),
      address: (address != null ? address.value : this.address),
      hasServiceAgreement: (hasServiceAgreement != null
          ? hasServiceAgreement.value
          : this.hasServiceAgreement),
      connectionType: (connectionType != null
          ? connectionType.value
          : this.connectionType));
}