(req *http.Request)
| 24 | } |
| 25 | |
| 26 | func JSRequestInfoFromRequest(req *http.Request) *JSRequestInfo { |
| 27 | if req == nil { |
| 28 | return nil |
| 29 | } |
| 30 | return &JSRequestInfo{ |
| 31 | Method: req.Method, |
| 32 | URL: req.URL.String(), |
| 33 | Proto: req.Proto, |
| 34 | ProtoMajor: req.ProtoMajor, |
| 35 | ProtoMinor: req.ProtoMinor, |
| 36 | Header: req.Header, |
| 37 | ContentLength: req.ContentLength, |
| 38 | TransferEncoding: req.TransferEncoding, |
| 39 | Host: req.Host, |
| 40 | RemoteAddr: req.RemoteAddr, |
| 41 | RequestURI: req.RequestURI, |
| 42 | } |
| 43 | } |
| 44 | |
| 45 | type JSDstInfo struct { |
| 46 | Network string `json:"network"` |
no test coverage detected