1. <tt id="5hhch"><source id="5hhch"></source></tt>
    1. <xmp id="5hhch"></xmp>

  2. <xmp id="5hhch"><rt id="5hhch"></rt></xmp>

    <rp id="5hhch"></rp>
        <dfn id="5hhch"></dfn>

      1. SUN認(rèn)證考試知識(shí)點(diǎn):Java Socket通信讀取相關(guān)信息代碼

        時(shí)間:2020-09-26 13:19:34 SUN認(rèn)證 我要投稿

        SUN認(rèn)證考試知識(shí)點(diǎn):Java Socket通信讀取相關(guān)信息代碼

          Java Socket通信讀取有不少需要我們注意的知識(shí)點(diǎn)。當(dāng)我們?cè)谑褂玫臅r(shí)候有很多的問題擺在我們面前。下面我們就來詳細(xì)的`學(xué)習(xí)有關(guān)Java Socket通信讀取的相關(guān)代碼編寫。

        SUN認(rèn)證考試知識(shí)點(diǎn):Java Socket通信讀取相關(guān)信息代碼

          以下是Java Socket通信讀取的相關(guān)代碼。

          1.import java.io.BufferedReader;

          2.import java.io.BufferedWriter;

          3.import java.io.File;

          4.import java.io.FileWriter;

          5.import java.io.InputStreamReader;

          6.import java.net.URL;public class URLReader {

          7./**

          8.* @param args

          9.* @throws Exception

          10.*/

          11.public static void main(String[] args) throws Exception {

          12.// 聲明拋出所有例外

          13.URL tirc = new URL(http://www.sina.com);

          14.File writeFile = new File("d:\\style_1.html");

          15.// 構(gòu)建一URL對(duì)象14100

          16.BufferedReader in = new BufferedReader(new InputStreamReader(tirc.openStream()));

          17.BufferedWriter bos = new BufferedWriter(new FileWriter(writeFile));

          18.//byte[] b=new byte[4096];

          19.String inputLine;

          20.// 使用openStream得到一輸入流并由此構(gòu)造一個(gè)BufferedReader對(duì)象

          21.while ((ininputLine = in.readLine()) != null){

          22.bos.write(inputLine);

          23.System.out.println(inputLine);

          24.}

          25.bos.flush();

          26.in.close();

          27.bos.close();

          28.}

          29.}

        【SUN認(rèn)證考試知識(shí)點(diǎn):Java Socket通信讀取相關(guān)信息代碼】相關(guān)文章:

        SUN認(rèn)證考試知識(shí)點(diǎn):java讀取文件內(nèi)容的函數(shù)11-05

        Sun java認(rèn)證考試答案11-12

        Sun Java認(rèn)證考試科目10-03

        sun java認(rèn)證考試介紹10-03

        sun java認(rèn)證考試報(bào)考指南10-03

        SUN JAVA認(rèn)證介紹05-13

        Sun java認(rèn)證考試真題答案07-19

        Sun認(rèn)證Java開發(fā)員考試介紹10-25

        Sun Java認(rèn)證考試教材教輔10-03

        国产高潮无套免费视频_久久九九兔免费精品6_99精品热6080YY久久_国产91久久久久久无码

        1. <tt id="5hhch"><source id="5hhch"></source></tt>
          1. <xmp id="5hhch"></xmp>

        2. <xmp id="5hhch"><rt id="5hhch"></rt></xmp>

          <rp id="5hhch"></rp>
              <dfn id="5hhch"></dfn>