Skip to content

Commit

Permalink
di for logger
Browse files Browse the repository at this point in the history
  • Loading branch information
徐志强 committed Jul 27, 2018
1 parent 37ff427 commit 4c42e55
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
10 changes: 10 additions & 0 deletions logger.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
package qrpc

type logger interface {
Info(msg ...interface{})
Error(msg ...interface{})
Debug(msg ...interface{})
}

// Logger is exported logger interface
var Logger logger
2 changes: 1 addition & 1 deletion qrpc.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const (
StreamFlag FrameFlag = 1 << iota
// StreamEndFlag denotes the end of a stream
StreamEndFlag
// StreamRstFlag is sent to request cancellation of a stream or to indicate that an error condition has occurred (TODO)
// StreamRstFlag is sent to request cancellation of a stream or to indicate that an error condition has occurred
StreamRstFlag
// NBFlag means it should be handled nonblockingly, it's implied for streamed frames
NBFlag
Expand Down

0 comments on commit 4c42e55

Please sign in to comment.