status-go/vendor/github.com/libp2p/go-mplex
Adam Babik c9e99c432d migrate to go 1.12 and go modules 2019-06-12 13:12:00 +02:00
..
.travis.yml migrate to go 1.12 and go modules 2019-06-12 13:12:00 +02:00
LICENSE migrate to go 1.12 and go modules 2019-06-12 13:12:00 +02:00
README.md migrate to go 1.12 and go modules 2019-06-12 13:12:00 +02:00
codecov.yml migrate to go 1.12 and go modules 2019-06-12 13:12:00 +02:00
deadline.go migrate to go 1.12 and go modules 2019-06-12 13:12:00 +02:00
go.mod migrate to go 1.12 and go modules 2019-06-12 13:12:00 +02:00
go.sum migrate to go 1.12 and go modules 2019-06-12 13:12:00 +02:00
multiplex.go migrate to go 1.12 and go modules 2019-06-12 13:12:00 +02:00
stream.go migrate to go 1.12 and go modules 2019-06-12 13:12:00 +02:00

README.md

go-mplex

Discourse posts

A super simple stream muxing library implementing mplex.

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