Vous ne pouvez pas sélectionner plus de 25 sujets
Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.
|
- package main
-
- import "net/http"
-
- //
- //InWechatMsg what we received currently from wechat
- type InWechatMsg struct {
- header CommonHeader
- body interface{} //dynamic type
- req *http.Request
- instantResponse chan string //instance reply channel
- }
-
- func (m *InWechatMsg) init() {
- m.instantResponse = make(chan string)
- }
-
- func (m *InWechatMsg) destroy() {
- close(m.instantResponse)
- }
-
- func (m *InWechatMsg) immediateResponse(s string) {
- m.instantResponse <- s
- }
|