libp2p/transports/transport

    Dark Mode
Search:
Group by:
  Source   Edit

Types

Transport = ref object of RootObj
  addrs*: seq[MultiAddress]
  running*: bool
  upgrader*: Upgrade
  networkReachability*: NetworkReachability
  Source   Edit
TransportError = object of LPError
  Source   Edit

Procs

proc dial(self: Transport; address: MultiAddress;
          peerId: Opt[PeerId] = Opt.none(PeerId)): Future[Connection] {....gcsafe,
    raises: [], tags: [].}
  Source   Edit
proc newTransportClosedError(parent: ref Exception = nil): ref LPError {.
    ...raises: [], tags: [].}
  Source   Edit

Methods

method accept(self: Transport): Future[Connection] {.base, ...gcsafe, raises: [],
    tags: [].}
accept incoming connections   Source   Edit
method dial(self: Transport; hostname: string; address: MultiAddress;
            peerId: Opt[PeerId] = Opt.none(PeerId)): Future[Connection] {.base,
    ...gcsafe, raises: [], tags: [].}
dial a peer   Source   Edit
method handles(self: Transport; address: MultiAddress): bool {.base, ...gcsafe,
    raises: [], tags: [].}
check if transport supports the multiaddress   Source   Edit
method start(self: Transport; addrs: seq[MultiAddress]): Future[void] {.base,
    stackTrace: false, ...raises: [], gcsafe, raises: [], raises: [],
    tags: [RootEffect].}
start the transport   Source   Edit
method stop(self: Transport): Future[void] {.base, stackTrace: false,
    ...raises: [], gcsafe, raises: [], raises: [], tags: [RootEffect].}
stop and cleanup the transport including all outstanding connections   Source   Edit
method upgrade(self: Transport; conn: Connection; peerId: Opt[PeerId]): InternalRaisesFuture[
    Muxer, (CancelledError, LPError)] {.base, stackTrace: false, ...raises: [],
                                        gcsafe, raises: [], raises: [], tags: [].}
  Source   Edit