muxed stream

This commit is contained in:
zixuanzh
2018-11-11 18:03:04 -05:00
parent 55dae3ed1e
commit fe20d25882
5 changed files with 122 additions and 18 deletions

View File

@ -1,11 +1,18 @@
from abc import ABC, abstractmethod
class IMuxedConn(ABC):
"""
reference: https://github.com/libp2p/go-stream-muxer/blob/master/muxer.go
"""
# TODO closer
@abstractmethod
def close(self):
"""
close connection
:return: true if successful
"""
pass
@abstractmethod
def is_closed(self):