This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # 服务器端接收代码 | |
| ``` | |
| BufferedReader bufferReader = request.getReader();//获取头部参数信息 | |
| StringBuffer buffer = new StringBuffer(); | |
| String line = " "; | |
| while ((line = bufferReader.readLine()) != null) { | |
| buffer.append(line); | |
| } | |
| String rtnString = buffer.toString(); | |
| ``` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /bin/ | |
| /target/ | |
| .* | |
| *.class | |
| /build/ | |
| # Package Files # | |
| *.jar | |
| *.war | |
| *.ear |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import org.apache.http.HttpEntity; | |
| import org.apache.http.HttpResponse; | |
| import org.apache.http.client.ClientProtocolException; | |
| import org.apache.http.client.ResponseHandler; | |
| import org.apache.http.client.config.RequestConfig; | |
| import org.apache.http.client.methods.*; | |
| import org.apache.http.entity.StringEntity; | |
| import org.apache.http.impl.client.*; | |
| import org.apache.http.util.EntityUtils; |