Types
HandlerHolder = ref object protos*: seq[string] protocol*: LPProtocol match*: Matcher openedStreams: CountTable[PeerId]
- Source Edit
MultiStreamError = object of LPError
- Source Edit
MultistreamSelect = ref object of RootObj handlers*: seq[HandlerHolder] codec*: string
- Source Edit
Procs
proc addHandler(m: MultistreamSelect; codec: string; handler: LPProtoHandler | LPProtocolHandler; matcher: Matcher = nil) {....raises: [].}
- helper to allow registering pure handlers Source Edit
proc addHandler(m: MultistreamSelect; codec: string; protocol: LPProtocol; matcher: Matcher = nil) {....raises: [], tags: [RootEffect].}
- Source Edit
proc addHandler(m: MultistreamSelect; codecs: seq[string]; protocol: LPProtocol; matcher: Matcher = nil) {....raises: [], tags: [].}
- Source Edit
proc handle(_: type MultistreamSelect; conn: Connection; protos: seq[string]; matchers = newSeq[Matcher](); active: bool = false): Future[string] {. stackTrace: false, ...raises: [], gcsafe, raises: [], raises: [].}
- Source Edit
proc handle(m: MultistreamSelect; conn: Connection; active: bool = false): Future[ void] {.stackTrace: false, ...raises: [], gcsafe, raises: [], raises: [], tags: [RootEffect].}
- Source Edit
proc list(m: MultistreamSelect; conn: Connection): Future[seq[string]] {. stackTrace: false, ...raises: [], gcsafe, raises: [], raises: [], tags: [RootEffect].}
- list remote protos requests on connection Source Edit
proc new(T: typedesc[MultistreamSelect]): T:type {....raises: [].}
- Source Edit
proc select(_: MultistreamSelect | type MultistreamSelect; conn: Connection; proto: seq[string]): Future[string] {.stackTrace: false, ...raises: [], gcsafe, raises: [], raises: [].}
- Source Edit
proc select(_: MultistreamSelect | type MultistreamSelect; conn: Connection; proto: string): Future[bool] {.stackTrace: false, ...raises: [], gcsafe, raises: [], raises: [].}
- Source Edit
proc select(m: MultistreamSelect; conn: Connection): Future[bool] {....raises: [], tags: [RootEffect].}
- Source Edit
proc start(m: MultistreamSelect): Future[void] {.stackTrace: false, ...raises: [], gcsafe, raises: [], raises: [], tags: [RootEffect].}
- Source Edit
proc stop(m: MultistreamSelect): Future[void] {.stackTrace: false, ...raises: [], gcsafe, raises: [], raises: [], tags: [RootEffect].}
- Source Edit