]>
Commit | Line | Data |
---|---|---|
1 | package hotline | |
2 | ||
3 | // HandlerFunc is the signature of a func to handle a Hotline transaction. | |
4 | type HandlerFunc func(*ClientConn, *Transaction) []Transaction | |
5 | ||
6 | func (s *Server) HandleFunc(tranType [2]byte, handler HandlerFunc) { | |
7 | s.handlers[tranType] = handler | |
8 | } | |
9 | ||
10 | // The total size of a chat message data field is 8192 bytes. | |
11 | const LimitChatMsg = 8192 |