diff --git a/utils/stream.go b/utils/stream.go new file mode 100644 index 00000000..b4d73ce7 --- /dev/null +++ b/utils/stream.go @@ -0,0 +1,16 @@ +package utils + +import ( + "io" + + "github.com/lucas-clemente/quic-go/protocol" +) + +// Stream is the interface for QUIC streams +type Stream interface { + io.Reader + io.Writer + io.Closer + StreamID() protocol.StreamID + CloseRemote(offset protocol.ByteCount) +} diff --git a/utils/utils.go b/utils/utils.go index cf256795..f6c4e03b 100644 --- a/utils/utils.go +++ b/utils/utils.go @@ -3,19 +3,8 @@ package utils import ( "bytes" "io" - - "github.com/lucas-clemente/quic-go/protocol" ) -// Stream is the interface for QUIC streams -type Stream interface { - io.Reader - io.Writer - io.Closer - StreamID() protocol.StreamID - CloseRemote(offset protocol.ByteCount) -} - // ReadUintN reads N bytes func ReadUintN(b io.ByteReader, length uint8) (uint64, error) { var res uint64