HolePunchServiceImpl constructor

HolePunchServiceImpl(
  1. Host _host,
  2. IDService _ids,
  3. List<MultiAddr> _listenAddrs(), {
  4. HolePunchOptions? options,
})

Creates a new holepunch service

listenAddrs MUST only return public addresses.

Implementation

HolePunchServiceImpl(this._host, this._ids, this._listenAddrs, {
  HolePunchOptions? options,
}) :
  _tracer = options?.tracer,
  _filter = options?.filter {

  _incrementRefCount();
  _waitForPublicAddr();
}