(String url,String raw,byte[] byteImg)
| 28 | private byte[] byteImg; |
| 29 | |
| 30 | public HttpClient(String url,String raw,byte[] byteImg){ |
| 31 | this.url = url; |
| 32 | this.raw = processLine(raw); |
| 33 | this.byteImg = byteImg; |
| 34 | //解析标签 |
| 35 | parseLabel(); |
| 36 | //解析Request各个属性 |
| 37 | parserRequest(); |
| 38 | //更新Content-Length |
| 39 | updateContentLength(); |
| 40 | } |
| 41 | |
| 42 | /** |
| 43 | * 将请求包头中\n替换为\r\n,因为\n可能会导致某些服务器报错,无法正确识别请求包。 |
nothing calls this directly
no test coverage detected