锘??xml version="1.0" encoding="utf-8" standalone="yes"?>免费国产一区,亚洲国产成人久久综合一区,99精品黄色片免费大全http://www.aygfsteel.com/tngchao/鎴戝湪嫻瘋竟娓歌崱錛屼絾鍗存湭韙忚凍嫻蜂腑zh-cnSat, 05 Jul 2025 13:43:00 GMTSat, 05 Jul 2025 13:43:00 GMT60- 涓嬭澆緗戦〉錛岄〉闈笂涓枃涔辯爜闂鐨勮В鍐?/title>http://www.aygfsteel.com/tngchao/archive/2006/08/08/62294.html鍞愭湞鍞愭湞Tue, 08 Aug 2006 02:01:00 GMThttp://www.aygfsteel.com/tngchao/archive/2006/08/08/62294.htmlhttp://www.aygfsteel.com/tngchao/comments/62294.htmlhttp://www.aygfsteel.com/tngchao/archive/2006/08/08/62294.html#Feedback0http://www.aygfsteel.com/tngchao/comments/commentRss/62294.htmlhttp://www.aygfsteel.com/tngchao/services/trackbacks/62294.html涓涓棶棰樺氨鏄紝鍦ㄥ鐞嗕竴涓綉欏電殑鏃跺欙紝涓嶈兘鐭ラ亾榪欎釜緗戦〉鐨勭紪鐮佸埌搴曟槸鏄粈涔堛?br />搴旇鐢╱rlcon.getContentEncoding()鍑芥暟鏉ュ彇銆備絾鏄紝鍦–SDN榪欎釜緗戦〉閲岄潰錛屽垰濂藉彇涓嶅埌銆?br />鍥犱負(fù)鎴戞兂錛屽畠娌℃湁鎶奵harset鏀懼埌鍗曠嫭鐨凪eta鏍囩閲岄潰銆?br />


聽1聽package聽mynet;
聽2聽
聽3聽import聽java.io.IOException;
聽4聽import聽java.io.InputStream;
聽5聽import聽java.net.MalformedURLException;
聽6聽import聽java.net.URL;
聽7聽import聽java.util.Date;
聽8聽
聽9聽import聽sun.net.www.protocol.http.HttpURLConnection;
10聽
11聽public聽class聽URLDemo聽{
12聽聽聽聽聽public聽static聽void聽main(String[]聽args)聽{
13聽
14聽聽聽聽聽聽聽聽聽System.out.println("Starting
");
15聽聽聽聽聽聽聽聽聽int聽c;
16聽
17聽聽聽聽聽聽聽聽聽HttpURLConnection聽urlcon聽=聽null;
18聽聽聽聽聽聽聽聽聽try聽{
19聽聽聽聽聽聽聽聽聽聽聽聽聽URL聽url聽=聽new聽URL("http://www.csdn.net");
20聽聽聽聽聽聽聽聽聽聽聽聽聽try聽{
21聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽urlcon聽=聽(HttpURLConnection)聽url.openConnection();
22聽聽聽聽聽聽聽聽聽聽聽聽聽}聽catch聽(IOException聽e)聽{
23聽
24聽聽聽聽聽聽聽聽聽聽聽聽聽}
25聽聽聽聽聽聽聽聽聽聽聽聽聽System.out.println("the聽date聽is聽:"聽+聽new聽Date(urlcon.getDate()));
26聽聽聽聽聽聽聽聽聽聽聽聽聽System.out.println("content_type聽:"聽+聽urlcon.getContentType());
27聽聽聽聽聽聽聽聽聽聽聽聽聽try聽{
28聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽InputStream聽in聽=聽urlcon.getInputStream();
29聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽int聽all聽=聽in.available();
30聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽String聽webpage聽=聽null;
31聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽while聽(all聽>聽0)聽{
32聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽byte[]聽b聽=聽new聽byte[all];
33聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽in.read(b);
34聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽webpage聽=聽new聽String(b,聽"UTF-8");
35聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽System.out.println(webpage);
36聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽all聽=聽in.available();
37聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽Thread.sleep(2000);//緇欏畠鐐逛笅杞界殑鏃墮棿錛屾瘡涓ょ閽熻鍙栦竴嬈?/span>
38聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽}
39聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽in.close();
40聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽System.out.println(webpage);
41聽聽聽聽聽聽聽聽聽聽聽聽聽}聽catch聽(Exception聽e)聽{
42聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽System.out.println(""聽+聽e);
43聽聽聽聽聽聽聽聽聽聽聽聽聽}
44聽
45聽聽聽聽聽聽聽聽聽}聽catch聽(MalformedURLException聽e)聽{
46聽聽聽聽聽聽聽聽聽聽聽聽聽System.out.println(""聽+聽e);
47聽聽聽聽聽聽聽聽聽}
48聽
49聽聽聽聽聽}
50聽
51聽}

]]> - 緇堜簬鐢寵鍒頒簡錛侊紒http://www.aygfsteel.com/tngchao/archive/2006/06/30/56033.html鍞愭湞鍞愭湞Fri, 30 Jun 2006 13:21:00 GMThttp://www.aygfsteel.com/tngchao/archive/2006/06/30/56033.htmlhttp://www.aygfsteel.com/tngchao/comments/56033.htmlhttp://www.aygfsteel.com/tngchao/archive/2006/06/30/56033.html#Feedback0http://www.aygfsteel.com/tngchao/comments/commentRss/56033.htmlhttp://www.aygfsteel.com/tngchao/services/trackbacks/56033.html闃呰鍏ㄦ枃

]]>
主站蜘蛛池模板:
焉耆|
门头沟区|
江源县|
漳州市|
绥宁县|
武穴市|
临安市|
平罗县|
灵山县|
东城区|
石首市|
永善县|
宝鸡市|
佛坪县|
高雄市|
保靖县|
常德市|
永春县|
兴化市|
五莲县|
江西省|
陵水|
屏东市|
白朗县|
濉溪县|
侯马市|
西充县|
额济纳旗|
镇赉县|
靖西县|
遂溪县|
台南县|
汤原县|
弥勒县|
台东县|
静乐县|
陈巴尔虎旗|
阳谷县|
招远市|
长垣县|
濮阳市|