bind static method

Future<IOServer> bind(
  1. Object address,
  2. int port, {
  3. int? backlog,
})

Calls HttpServer.bind and wraps the result in an IOServer.

Implementation

static Future<IOServer> bind(Object address, int port, {int? backlog}) async {
  backlog ??= 0;
  var server = await HttpServer.bind(address, port, backlog: backlog);
  return IOServer(server);
}