我正在閱讀http.Server文檔中的類型聲明,我遇到了這個。type Server struct { Addr string // TCP address to listen on, ":http" if empty // more...}如果調(diào)用srv.ListenAndServe()并且srv.Addr是空字符串,ListenAndServe則將傳遞":http"給net.Listen( http/server.go )。什么":http"意思?
- 1 回答
- 0 關(guān)注
- 182 瀏覽
添加回答
舉報
0/150
提交
取消