copyWith method

EvOptions copyWith({
  1. List<EvConnectorType>? connectorTypes,
  2. double? minimumChargingRateKw,
})

Implementation

EvOptions copyWith({
  List<EvConnectorType>? connectorTypes,
  double? minimumChargingRateKw,
}) {
  return EvOptions(
    connectorTypes:
        ((connectorTypes?.isNotEmpty ?? false) ? connectorTypes : null) ??
        this.connectorTypes,
    minimumChargingRateKw:
        minimumChargingRateKw ?? this.minimumChargingRateKw,
  );
}