mirror of
https://github.com/cwinfo/yggdrasil-go.git
synced 2025-07-06 01:44:06 +00:00
Work in progress, add a linkInterfaceMsgIO interface type and make stream implement it, this will be used by link
This commit is contained in:
@ -17,6 +17,15 @@ type link struct {
|
||||
interfaces map[string]*linkInterface
|
||||
}
|
||||
|
||||
type linkInterfaceMsgIO interface {
|
||||
readMsg() ([]byte, error)
|
||||
writeMsg([]byte) (int, error)
|
||||
close() error
|
||||
// These are temporary workarounds to stream semantics
|
||||
_sendMetaBytes([]byte) error
|
||||
_recvMetaBytes() ([]byte, error)
|
||||
}
|
||||
|
||||
type linkInterface struct {
|
||||
name string
|
||||
link *link
|
||||
|
Reference in New Issue
Block a user