SocketClient1.java 374 Bytes
  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
package com.lyms.etl.socket;


import java.net.Socket;

public class SocketClient1 {
public static void main(String args[])throws Exception{
Socket socket = new Socket("192.168.0.5", 5208);
System.out.println("恭喜你连接成功!");
new Thread(new SocketThread1(socket)).start();
new Thread(new SocketThread2(socket)).start();
}
}