07 2014 档案

摘要:找到CCDirector.h,找到void popScene();在下面加上一段类模板template void popSceneWithTransition(float t){ CCASSERT(_runningScene != nullptr, "running scene should ... 阅读全文
posted @ 2014-07-31 20:22 自由出土文物 阅读(1616) 评论(0) 推荐(1) 编辑
摘要:如果数据库连接只有一个,在某个时间点(指的是某个及其短的时间内),多个读写的话,会出问题,修改了下,加了个mutex,算是解决了此问题,贴下备忘var mutex sync.Mutexfunc (c *Client) Do(args ...interface{}) ([]string, error)... 阅读全文
posted @ 2014-07-18 22:07 自由出土文物 阅读(888) 评论(3) 推荐(0) 编辑
摘要:package mainimport ( "fmt" "time")func deskGoRoutine(index int, userChannel chan string, deskChannel chan string) { for { fmt.Println(... 阅读全文
posted @ 2014-07-11 12:00 自由出土文物 阅读(301) 评论(0) 推荐(0) 编辑
摘要:由于某个需求,需要如题的转换,废话不多说,直接贴代码了,其实挺丑了,备用了func (this *Server) socketParserHandler(client *genTcpServer.Client, fullData []byte) { fmt.Println("original ... 阅读全文
posted @ 2014-07-08 19:10 自由出土文物 阅读(7270) 评论(0) 推荐(0) 编辑
摘要:网上看到的,记录下,备用package mainimport ( "net/http")func main() { http.Handle("/", http.FileServer(http.Dir("./"))) http.ListenAndServe(":8080", nil)... 阅读全文
posted @ 2014-07-01 12:37 自由出土文物 阅读(1410) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示