TcpClient.withStringTerminator constructor
TcpClient.withStringTerminator(})
Same as the default constructor, but builds the terminatorBytes from the UTF8 encoding of the given string.
Implementation
TcpClient.withStringTerminator(
this.host,
this.port,
String terminatorString, {
this.timeout = const Duration(seconds: 2),
}) {
terminatorBytes = Uint8List.fromList(terminatorString.codeUnits);
}