Replies: 1 comment
-
Context 是 Conn 用于在生命周期内的传递的信息。
用于分包和组包,序列化和反序列化目前要在 React() 里做。
没有。 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
我不太理解这里的Context接口函数,说明是返回一个用户自定义上下文,这个上下文主要是干什么的?一般用在什么场景?
gnet/gnet.go
Line 95 in 51fb738
ICodec的作用是在发包和解包的时候,直接序列化和反序列化指定的类型吗?
gnet/codec.go
Line 31 in 51fb738
ReadN()函数是读取到byte到指定的位置获取[]byte数据,那有没有我只读取指定区间位置(比如32-36)的[]byte呢?
Beta Was this translation helpful? Give feedback.
All reactions