copyWith method

ModbusTcpConnectionDTO copyWith({
  1. String? name,
  2. String? tcpAddress,
  3. int? port,
  4. int? unitId,
  5. String? propertySpec,
})

Implementation

ModbusTcpConnectionDTO copyWith(
    {String? name,
    String? tcpAddress,
    int? port,
    int? unitId,
    String? propertySpec}) {
  return ModbusTcpConnectionDTO(
      name: name ?? this.name,
      tcpAddress: tcpAddress ?? this.tcpAddress,
      port: port ?? this.port,
      unitId: unitId ?? this.unitId,
      propertySpec: propertySpec ?? this.propertySpec);
}