【Golang】简单实现web服务器返回json数据
package mainimport ( "io" "net/http" "log" "encoding/json")type Data struct{ Name string Age int}type Ret struct{ Code int Param string Msg string Data []Data}func HelloServer(w http.ResponseWriter, req *http.Request) { da
原创
2021-11-25 18:57:24 ·
1334 阅读 ·
0 评论