- 博客(5)
- 收藏
- 关注
原创 跨域问题
公司如果想把所有后台接口打包成服务,那么必然会进行前后台分离。分离后自然会出现跨域问题:前后台分离之后的跨域问题代码:package com.xcjt.filter;import java.io.IOException;import javax.servlet.Filter;import javax.servlet.FilterChain;import java
2018-02-05 09:54:08
139
原创 jdbcTemplate与simjdbcTemplate区别
jdbcTemplate可以根据sql执行结果强制将结果转化为对应类型如:String sql ="select COUNT(1) from Device d with (NOLOCK) ,DeviceType dt with (NOLOCK) where d.deviceTypeID=dt.deviceTypeID and d.gcID=? and dt.systemID=? ";
2018-01-31 16:32:31
248
原创 http接口
//以下是post提交方式,如果是get方式直接url跟要传输内容即可private String httpUrl = "http://120.92.9.173/WDBim/Service/DataMapService.svc";private String method = "datamap";public String doPost(String dataStr) throws
2018-01-11 15:22:49
216
原创 tcp协议传输过程
private int contentMsgBufferSize = 10000000;private InetSocketAddresssocketAddress;private SocketChannelsckChannel;private ByteBufferbuffMsgContent = ByteBuffer.allocate(contentMsgBuffer
2018-01-11 15:16:24
369
转载 http传输坑
http传输请求头改变之后的一些坑http://www.importnew.com/26779.html错误写法// StringEntity s = new StringEntity(dataStr);// s.setContentEncoding("UTF-8");// s.setContentType("application/json");//
2018-01-11 15:02:22
253
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人