connect abstract method
This must connect to host
:port
and initialize the streams accordingly.
domain
is the domain that TLS should be validated against, in case the Socket
provides TLS encryption. Returns true if the connection has been successfully
established. Returns false if the connection has failed.
Implementation
Future<bool> connect(String domain, {String? host, int? port});