go让日志显示行数
log.SetFlags(log.Lshortfile | log.LstdFlags)
一个简单的golang http封装
1 | func HttpGetCall(url string, params map[string]string, cooikes []*http.Cookie, res interface{}) error { |
1 | func NewRequestOptions() *grequests.RequestOptions { |
返回类型的结构体
1 | type Message struct { |
调用例子:
1 | func GetUserInfoByAccount(account string) (*protocol.UserCenterFilterUserInfo, int) { |