Java socket ÈëÃűà³ÌʵÀý
ÕâÊÇÒ»¸öC/SÖ®¼äͨÐŵÄÀý×Ó,ÔÚJDK1.4ϲâÊÔͨ¹ý.
//·þÎñÆ÷¶ËÔ´³ÌÐòtcpserver.java
import java.io.*;
import java.net.*;
public class tcpserver
{
public static void main(String[] args) throws IOException
{
ServerSocket svrsoc=null;
Socket soc=null;
DataInputStream in=null;
PrintStream out=null;
InetAddress clientIP=null;
String str=null;
try
{
svrsoc=new ServerSocket(8000);
System.out.println("Server start....");
soc=svrsoc.accept();
in=new DataInputStream(soc.getInputStream());
out=new PrintStream(soc.getOutputStream());
clientIP=soc.getInetAddress();
System.out.println("Client's IP address:"+clientIP);
out.println("welcome.....");
str=in.readLine();
while (!str.equals("quit"))
{
 
Ïà¹ØÎĵµ£º
×î½ü¿ªÊ¼ÔÚ¿´java£¬¶ÔAppletÕâ½Ú±È½Ï¸ÐÐËȤ£¬¸ÄÁ˸ÄÊéÉϵĴúÂ룬Ȩµ±Áô¸öÓ¡¼Ç
import java.awt.*;
import java.applet.*;
public class HelloApplet extends Applet
{
Font f1 = new Font("Times New Roman", Font.PLAIN, 12);
Font f2 = new Font("ËÎÌå", Font.BOLD, 24);
Font f3 = new Font("ºÚÌå", Fon ......
ÔÚ±àÒëandroid code ³öÏÖ°æ±¾²»¶ÔµÄÎÊÌ⣺
ÃèÊöÈçÏ£º
You are attempting to build with the incorrect version
of java.
Your version is: java version "1.6.0_17".
The correct version is: 1.5.
Please follow the machine setup instructions at
http://source.android.com/download
ÍøÉÏÓÐÈËÌṩ½â¾ö·½·¨ÈçÏ ......
Ò»¡¢JDBCµ÷Óô洢¹ý³Ì
creat proc proc_select
¡¡¡¡@pid varchar(20)
¡¡¡¡@address varchar(20) output
¡¡¡¡as
¡¡¡¡select @address=address from userinfo where pid=@pid
¡¡¡¡go
¡¡¡¡ÓÃjavaµ÷ÓÃ:
¡¡¡¡class.forName(\"sun.jdbc.odbc.JdbcOdbcDriver\"); //¼ÓÔØÇý¶¯
¡¡¡¡Connection con=DriverManager.ge ......
1995Äê5ÔÂ23ÈÕ£¬JavaÓïÑÔµ®Éú
1996Äê1Ô£¬µÚÒ»¸öJDK-JDK1.0µ®Éú
1996Äê4Ô£¬10¸ö×îÖ÷ÒªµÄ²Ù×÷ϵͳ¹©Ó¦ÉÌÉêÃ÷½«ÔÚÆä²úÆ·ÖÐǶÈëJAVA¼¼Êõ
1996Äê9Ô£¬Ô¼8.3Íò¸öÍøÒ³Ó¦ÓÃÁËJAVA¼¼ÊõÀ´ÖÆ×÷
1997Äê2ÔÂ18ÈÕ£¬JDK1.1·¢²¼
1997Äê4ÔÂ2ÈÕ£¬JavaOne»áÒéÕÙ¿ª£¬²ÎÓëÕßÓâÒ»ÍòÈË£¬´´µ±Ê±È«ÇòͬÀà»áÒ鹿ģ֮¼Í¼
1997Äê9 ......
import java.io.BufferedReader;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStreamReader;
import sun.net.TelnetOutputStream;
import sun.net.TelnetInputStream;
import sun.net.ftp.FtpClient;
public class download ...{
& ......