- 博客(9)
- 资源 (1)
- 收藏
- 关注
转载 json to xml 和 xml to json
/** * json string convert to xml string */ public static String json2xml(String json) { StringReader input = new StringReader(json); StringWriter output = new StringWriter(); JsonXMLConfig
2018-01-25 22:19:18 587
翻译 post和get请求 (httpclient)
package day03; import java.util.ArrayList; import java.util.List; import org.apache.http.HttpEntity; import org.apache.http.HttpStatus; import org.apache.http.NameValuePair; import org.apache.http.c
2018-01-25 21:58:42 226
转载 post请求
/** * post请求(用于请求json格式的参数) * * @param url * @param params * @return */ public static String doPost(String url, Map params,Boolean flag) throws Exception { CloseableHttpClient http
2018-01-25 21:52:13 419
原创 map转json与json 转map
//map转json格式 JSONObject jsonObject = JSONObject.fromObject(map); //json转map形式 public static Map parseJSON2Map(String jsonStr){ Map map = new HashMap(); JSONObject json = J
2018-01-25 21:39:34 865
转载 用jdk生成webservice客户端代码(调用免费接口)
步骤一:http://www.webxml.com.cn/WebServices/WeatherWebService.asmx?wsdl 复制源代码 修改里面 s:elementref="s:schema"/> 变成 <s:any minOccurs="2" maxOccurs="2"/> 结果如下: http://schemas.xmlsoap.org/w
2017-11-28 22:28:05 1345
原创 java中的编码与解码问题
解码: public String(byte[] byte)用系统平台默认的字符集 进行解码指定的byte 数组 public String(byte[] bytes. String charsetName)进行指定的编码表解码byte数组 编码: public byte[] getBytes() 使用平台的默认字符集将此String编码为byte序列,并将结果存储到一个新的byte 数组
2016-03-15 22:59:01 257
原创 Jquery的样式切换
Insert title here $(document).ready(function(){ $("#buttonId").click(function(){ $("#divId").toggleClass("divClass"); }); }); .divClass{ border:1px solid #f00; width:1800px;
2016-03-14 22:50:59 238
原创 Jquery页面滚动
Insert title here $(document).ready(function(){ //1 初始化个数 for(var i = 0 ; i //1.1 创建一个div createDiv(); } //2 给body绑定 scroll 事件, 给整个窗体设置滚动事件 $(window).scroll(function(){ // * 距离可滚
2016-03-14 22:42:24 291
原创 java项目 主页面的分层(上-左右)
1.main.html代码如下 2.top.html代码如下 welcome to you come china 3.left.htmll代码如下 china 4.right.htmll代码如下 welcome 5.data.html ID 名臣 朝代 1 王安石 北宋
2016-03-13 22:50:02 519
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人