copyWith method
DeviceDetailsV2
copyWith({ - DeviceV2? device,
- PowerSourceV2? powerSource,
- SwitchStateV2? switchState,
- CoolingTypeV2? coolingType,
- ConnectionTypeV2? connectionType,
- bool? hasServiceAgreement,
- DateTime? serviceAgreementBeginDate,
- ServiceAgreementTermV2? serviceAgreementTerm,
- int? serviceAgreementTermMonths,
- int? serviceAgreementTermDays,
- DateTime? lastRanTimestamp,
- int? totalRuntimeMinutes,
- int? runtimeSinceLastMaintenanceMinutes,
- String? addedBy,
- List<String>? associatedUsers,
- String? latestFirmware,
- DateTime? controllerClockTimestamp,
- String? controllerType,
- String? fuelType,
- double? batteryVoltageV,
- double? engineCoolantTempF,
- double? engineFrequencyHz,
- double? engineSpeedRpm,
- double? lubeOilTempF,
- double? controllerTempF,
- double? engineCompartmentTempF,
- double? engineOilPressurePsi,
- bool? engineOilPressureOk,
- double? generatorLoadW,
- double? generatorLoadPercent,
- double? generatorVoltageAvgV,
- double? setOutputVoltageV,
- double? utilityVoltageV,
- String? engineState,
- PeripheralV2? loadShed,
- PeripheralV2? pim,
})
Implementation
DeviceDetailsV2 copyWith(
{DeviceV2? device,
enums.PowerSourceV2? powerSource,
enums.SwitchStateV2? switchState,
enums.CoolingTypeV2? coolingType,
enums.ConnectionTypeV2? connectionType,
bool? hasServiceAgreement,
DateTime? serviceAgreementBeginDate,
enums.ServiceAgreementTermV2? serviceAgreementTerm,
int? serviceAgreementTermMonths,
int? serviceAgreementTermDays,
DateTime? lastRanTimestamp,
int? totalRuntimeMinutes,
int? runtimeSinceLastMaintenanceMinutes,
String? addedBy,
List<String>? associatedUsers,
String? latestFirmware,
DateTime? controllerClockTimestamp,
String? controllerType,
String? fuelType,
double? batteryVoltageV,
double? engineCoolantTempF,
double? engineFrequencyHz,
double? engineSpeedRpm,
double? lubeOilTempF,
double? controllerTempF,
double? engineCompartmentTempF,
double? engineOilPressurePsi,
bool? engineOilPressureOk,
double? generatorLoadW,
double? generatorLoadPercent,
double? generatorVoltageAvgV,
double? setOutputVoltageV,
double? utilityVoltageV,
String? engineState,
PeripheralV2? loadShed,
PeripheralV2? pim}) {
return DeviceDetailsV2(
device: device ?? this.device,
powerSource: powerSource ?? this.powerSource,
switchState: switchState ?? this.switchState,
coolingType: coolingType ?? this.coolingType,
connectionType: connectionType ?? this.connectionType,
hasServiceAgreement: hasServiceAgreement ?? this.hasServiceAgreement,
serviceAgreementBeginDate:
serviceAgreementBeginDate ?? this.serviceAgreementBeginDate,
serviceAgreementTerm: serviceAgreementTerm ?? this.serviceAgreementTerm,
serviceAgreementTermMonths:
serviceAgreementTermMonths ?? this.serviceAgreementTermMonths,
serviceAgreementTermDays:
serviceAgreementTermDays ?? this.serviceAgreementTermDays,
lastRanTimestamp: lastRanTimestamp ?? this.lastRanTimestamp,
totalRuntimeMinutes: totalRuntimeMinutes ?? this.totalRuntimeMinutes,
runtimeSinceLastMaintenanceMinutes:
runtimeSinceLastMaintenanceMinutes ??
this.runtimeSinceLastMaintenanceMinutes,
addedBy: addedBy ?? this.addedBy,
associatedUsers: associatedUsers ?? this.associatedUsers,
latestFirmware: latestFirmware ?? this.latestFirmware,
controllerClockTimestamp:
controllerClockTimestamp ?? this.controllerClockTimestamp,
controllerType: controllerType ?? this.controllerType,
fuelType: fuelType ?? this.fuelType,
batteryVoltageV: batteryVoltageV ?? this.batteryVoltageV,
engineCoolantTempF: engineCoolantTempF ?? this.engineCoolantTempF,
engineFrequencyHz: engineFrequencyHz ?? this.engineFrequencyHz,
engineSpeedRpm: engineSpeedRpm ?? this.engineSpeedRpm,
lubeOilTempF: lubeOilTempF ?? this.lubeOilTempF,
controllerTempF: controllerTempF ?? this.controllerTempF,
engineCompartmentTempF:
engineCompartmentTempF ?? this.engineCompartmentTempF,
engineOilPressurePsi: engineOilPressurePsi ?? this.engineOilPressurePsi,
engineOilPressureOk: engineOilPressureOk ?? this.engineOilPressureOk,
generatorLoadW: generatorLoadW ?? this.generatorLoadW,
generatorLoadPercent: generatorLoadPercent ?? this.generatorLoadPercent,
generatorVoltageAvgV: generatorVoltageAvgV ?? this.generatorVoltageAvgV,
setOutputVoltageV: setOutputVoltageV ?? this.setOutputVoltageV,
utilityVoltageV: utilityVoltageV ?? this.utilityVoltageV,
engineState: engineState ?? this.engineState,
loadShed: loadShed ?? this.loadShed,
pim: pim ?? this.pim);
}