Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

java Ïò·þÎñÆ÷¶Î·¢±¨ÎÄ¡£

       ¼òµ¥Ð´ÁËÒ»¸ö£¬Ö»ÊÇÑéÖ¤Ò»ÏÂÊý¾ÝÁ÷»¥Ïà´«ËÍ£¬¾ßÌ幦ÄÜ¿ÉÒÔ×Ô¼º¼Ótest.java ¿Í»§¶Ë£º¶ÁÈ¡1.xmlÎļþ·¢Ë͸øDataServer£¨servlet£©,¶ÁÈ¡servlet·µ»ØµÄÄÚÈÝDataServer.java ·þÎñÆ÷servlet:¶ÁÈ¡test·¢Ë͵ÄxmlÄÚÈÝ£¬°ÑÄÚÈÝÔÙ·µ»Ø¸ø¿Í»§¶Ë¡£
/**
 *  * ¿Í»§¶Ë£¬·¢ËÍxml
 */
import java.io.*;
import java.net.*;
public class test{
    public static void main(String[] args) throws Exception{
 
        /*³õʼ»¯*/
        java.net.URL url = new java.net.URL("http://localhost:8080/servlet/DataServer");
        java.net.URLConnection con = url.openConnection();
        con.setUseCaches(false);
        con.setDoOutput(true);
        con.setDoInput(true);
        /*»º´æ*/
        BufferedReader fin = new BufferedReader(new FileReader("E:\\1.xml"));
        StringBuffer stringbuffer = new StringBuffer();
        char ac[] = new char[8192];
        int i;
        while ((i = fin.read(ac)) > 0)
        stringbuffer.append(ac, 0, i);
        fin.close();
        /*·¢ËÍ*/
        DataOutputStream dataOut = new DataOutputStream(con.getOutputStream());
        dataOut.writeUTF(stringbuffer.toString());
        dataOut.flush();
     &nb


Ïà¹ØÎĵµ£º

JavaÃüÁîÐÐÖ´ÐдÓSQL 2000Êý¾Ý¿â×ªÒÆµ½2005Êý¾Ý¿â

1.ÏÂÔØ2005Êý¾Ý¿âÇý¶¯£¨sqljdbc.jar£©
2.ÕâʱҪÓÃEclipseµÈ¼¯³É¿ª·¢»·¾³£¬ÔÚbuild pathÀïÃæ°Ñ2000Êý¾Ý¿âÇý¶¯°üɾ³ýÁË£¬È»ºóµ¼½ø2005Êý¾Ý°ü¡£
3.°Ñ´úÂëÖÐ×¢²áÊý¾Ý¿âÇý¶¯µÄ´úÂë»»³É2005µÄ´úÂë¡£
È磺
Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver"); // 2005 version
Class.forName("com.microsoft.jdb ......

java°²×°Óë»·¾³ÅäÖÃ

ǰÑÔ£º
      ¹¤×÷Öо­³£»á½Ó´¥java£¬ËäÈ»ÔÚѧУʱÓÐC¡¢C++µÄ»ù´¡£¬¶Ô¼òµ¥µÄjava´úÂ뻹ÊÇÄÜÓ¦¸¶¹ýÈ¥£¬µ«ÊÇÓÉÓÚȱ·¦¶ÔjavaÉîÈëµÄѧϰºÍÀí½â£¬ÔÚʵ¼ÊʹÓÃʱÈÔÓÐÎÞ´ÓÏÂÊֵĸоõ¡£Ç°¶Îʱ¼äÔÚʦÐÖµÄÍÆ¼öÏÂÂòÁËjava¾­µä½Ì³Ì¡¶Core Java¡·½øÐÐѧϰ£¬Íâ¹úÈ˵ÄÊéдµÄ¾ÍÊDz»Ò»Ñù£¬ÓïÑÔ¼òÁ¶£¬²¢¸½ÓÐÏêϸµÄ´ú ......

java io ѧϰ


½ÚµãÁ÷
¸¸Àà
InputStream
OutputStream
Reader
Writer
Îļþ
FileInputStream
FileOutputStream
FileReader
FileWriter
Êý×é
ByteArrayInputStream
ByteOutputStream
CharArrayReader
CharArrayWriter
×Ö·û´®
ÎÞ
ÎÞ
StringReader
StringWriter
¹ÜµÀ
PipedInputStream
PipedOutputStream
PipedRead ......

JAVA RMIѧϰС½á

    ×î½üÔÚ¿´JAVA RMIºÍ·Ö²¼Ê½·½ÃæµÄ¶«Î÷£¬ÒòÎªÉæ¼°µÄÖªÊ¶ÃæÂù¹ã£¬ËùÒÔ×öÁËһЩ±Ê¼ÇºÍ¹éÄÉ£¬ÔÚ´Ë·ÖÏíһϣ¬»¶Ó­´ó¼ÒÖ¸Õý¡£OK£¬ÑÔ¹éÕý´«£¡
JAVAÔ¶³Ì·½·¨µ÷Óã¨Remote Method Invocation£©ÊÇJ2EEµÄºÜ¶à·Ö²¼Ê½¼¼ÊõµÄ»ù´¡£¬±ÈÈçRMI-IIOPÄËÖÁEJB. RMIʹµÃÔËÐÐÔÚÒ»¸öjavaÐéÄâ»úÉϵĶÔÏó¿ÉÒÔµ÷ÓÃÔËÐÐÔÚÁíÒ»¸öjavaÐ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ