ServerSocket serverSocket = new ServerSocket(port);
Socket socket = serverSocket.accept();
DataInputStream in = new DataInputStream(socket.getInputStream);
in.read();
Class.forName("com.mysql.cjconnect.jdbc.Driver")
String url = "jdbc:mysql://localhost:3306/Database?user=root&password=&useSSL=true&characterEncoing=utf8&serverTimeZone=UTC";
Connection con = DriverManager.getConnection(url);
DataOutputStream out = new DataOutputStream(socket.getOutpuStream);
out.write();
Socket socket = new Socket();
socket.connect(InetAddress, port);
DataInputStream in = new DataInputStream(socket.getInputStream);
in.read();
DataOutputStream out = new DataOutputStream(socket.getOutputStream);
out.write();
Mysql数据库
Idea
信息加载中,请等待
微信客服(速回)
微信客服(慢回)