摘要:
/** * 发送请求报文 * 注:不可以关闭流 否则会关闭对应的socket */ public static void send(Socket socket, byte[] msg) { DataOutputStream out=null; try { out = new DataOutputStream((socket.getOutputStream())); out.write(msg); out.flush(); } catch (IOException e) { e.printStackTrace(); } } ... 阅读全文