Isaac-DeFrain / go-mplex

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

go-mplex

Go Reference Discourse posts

A super simple stream muxing library implementing mplex.

Users should prefer yamux over mplex. We would like to deprecate mplex in the future.

Usage

mplex := multiplex.NewMultiplex(mysocket)

s, _ := mplex.NewStream()
s.Write([]byte("Hello World!"))
s.Close()

os, _ := mplex.Accept()
// echo back everything received
io.Copy(os, os)

The last gx published version of this module was: 0.2.35: QmWGQQ6Tz8AdUpxktLf3zgnVN9Vy8fcWVezZJSU3ZmiANj

About

License:MIT License


Languages

Language:Go 96.4%Language:JavaScript 3.0%Language:Nix 0.3%Language:Shell 0.3%