朱杰兵blog

          jonhney'blog
          posts - 140, comments - 1, trackbacks - 0, articles - 0

               摘要: package com.what21.service.demo02; import java.io.BufferedReader;import java.io.InputStreamReader;import java.io.OutputStream;import java.net.HttpURLConnection;import java.net.URL; public cl...  閱讀全文

          posted @ 2016-04-26 13:06 朱杰兵 閱讀(265) | 評論 (0)編輯 收藏

          http://www.cnblogs.com/siqi/p/3475222.html
          import java.io.InputStream; import java.io.OutputStream; import java.net.HttpURLConnection; import java.net.URL; /**  * 通過UrlConnection調(diào)用Webservice服務(wù)  *  */ public class App {      public static void main(String[] args) throws Exception {         //服務(wù)的地址         URL wsUrl = new URL("http://192.168.1.100:6789/hello");                  HttpURLConnection conn = (HttpURLConnection) wsUrl.openConnection();                  conn.setDoInput(true);         conn.setDoOutput(true);         conn.setRequestMethod("POST");         conn.setRequestProperty("Content-Type", "text/xml;charset=UTF-8");                  OutputStream os = conn.getOutputStream();                  //請求體         String soap = "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:q0=\"http://ws.itcast.cn/\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\">" +                        "<soapenv:Body> <q0:sayHello><arg0>aaa</arg0>  </q0:sayHello> </soapenv:Body> </soapenv:Envelope>";                  os.write(soap.getBytes());                  InputStream is = conn.getInputStream();                  byte[] b = new byte[1024];         int len = 0;         String s = "";         while((len = is.read(b)) != -1){             String ss = new String(b,0,len,"UTF-8");             s += ss;         }         System.out.println(s);                  is.close();         os.close();         conn.disconnect();     } }

          posted @ 2016-04-25 17:14 朱杰兵 閱讀(121) | 評論 (0)編輯 收藏

          isNotNull和isEmpty區(qū)別
          <= 和>=需要關(guān)鍵字替代

          posted @ 2016-04-14 10:13 朱杰兵 閱讀(78) | 評論 (0)編輯 收藏

          String time = DateUtils.formatDate(date, "yyyy-MM-dd HH:mm:ss");
          月MM大寫,分鐘mm小寫,HH小時(shí)大寫

          posted @ 2016-04-13 14:50 朱杰兵 閱讀(97) | 評論 (0)編輯 收藏

          t.dpt_time between to_date('2015/01/01','yyyy/mm/dd') and   
            to_date('2015/12/31','yyyy/mm/dd')
          將取不到12月31日0點(diǎn)以后的數(shù)據(jù)
          解決辦法 trunc一下trunc(t.dpt_time)


          posted @ 2016-04-13 13:23 朱杰兵 閱讀(104) | 評論 (0)編輯 收藏

          select to_char(sysdate,'yyyy-mm-dd hh24:mi:ss') from dual;
          select to_char(sysdate,'yyyy-mm-dd hh24:mm:ss') from dual;

          'yyyy-mm-dd hh24:mi:ss':mi 分鐘  'yyyy-mm-dd hh24:mm:ss':mm 月份 其中兩個(gè)都是月份


          posted @ 2016-03-07 11:12 朱杰兵 閱讀(99) | 評論 (0)編輯 收藏

          window-preference-java-code style-clean up 和formatter     導(dǎo)入
          見worksoftware formate by eclipse plugin

          posted @ 2016-01-14 16:39 朱杰兵 閱讀(119) | 評論 (0)編輯 收藏

          // File file=new File("F:\\top50.png");D:\worksoftware\apache-tomcat-7.0.27\apache-tomcat-7.0.27\webapps\jzbz\
          File file=new File(path+"\\images\\ceairLogo.png");

          HttpServletRequest request = (HttpServletRequest) Executions.getCurrent().getNativeRequest();
          String path = request.getSession().getServletContext().getRealPath("/");

          posted @ 2016-01-14 10:53 朱杰兵 閱讀(96) | 評論 (0)編輯 收藏

          varchar2(10) 可以存5個(gè)中文,10個(gè)字母

          posted @ 2015-12-15 15:31 朱杰兵 閱讀(113) | 評論 (0)編輯 收藏

          如果讓eclipse識(shí)別*.zul是xml格式文件呢:Window -->Preferences -->Generals --> Content Type -->Text --> xml --> 點(diǎn)擊add按鈕 -->輸入*.zul -->Ok      這樣*.zul擴(kuò)展的文件eclipse會(huì)識(shí)別其為xml文件格式

          posted @ 2015-10-22 09:41 朱杰兵 閱讀(416) | 評論 (0)編輯 收藏

          僅列出標(biāo)題
          共14頁: First 上一頁 4 5 6 7 8 9 10 11 12 下一頁 Last 
          主站蜘蛛池模板: 宜兰市| 循化| 浑源县| 濮阳县| 威海市| 米泉市| 鹿泉市| 沛县| 平湖市| 凌云县| 邮箱| 德清县| 寿宁县| 湘潭市| 两当县| 报价| 玉树县| 赤水市| 房产| 闸北区| 甘南县| 石阡县| 随州市| 齐河县| 宜黄县| 门头沟区| 永登县| 新津县| 金寨县| 承德市| 湖州市| 罗定市| 沧州市| 句容市| 贡觉县| 孟村| 苍梧县| 罗江县| 南雄市| 吉隆县| 砀山县|