Skip to content

Cistern/udpchan

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

udpchan Circle CI GoDoc

A tiny channel wrapper around UDP connections

Usage

It's pretty simple: call Connect or Listen and get a []byte channel back!

inbound, err := Listen(":9999", nil)
if err != nil {
	// handle err
}

outbound, err := Connect(":9999")
if err != nil {
	// handle err
}

message := []byte("foo")

// Send a message over UDP
outbound <- message

// Receive a message over UDP
read := <-inbound // = []byte("foo")

License

MIT

About

A tiny channel wrapper around UDP connections

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages