canDial method

  1. @override
bool canDial(
  1. PeerId peerId,
  2. MultiAddr addr
)
override

Returns whether the dialer can dial peer p at addr

Implementation

@override
bool canDial(PeerId peerId, MultiAddr addr) {
  // Check if any transport can dial this address
  for (final transport in _transports) {
    if (transport.canDial(addr)) {
      return true;
    }
  }

  return false;
}