String clientStr = new Scanner(System.in).nextLine(); clientOS.write(clientStr.getBytes()); //获取通道中的输入流 InputStream clientIS = server.getInputStream(); byte [] clientByte = new byte[1024]; int clientLen = clientIS.read(clientByte); System.out.println("静儿:"+new String(clien...
We must extend the Exception class from the java.lang package in order to produce a unique exception. User Define Exception class UserDefineException extends Exception { public UserDefineException(String s){ super(s); // calling parent Exception } } public class Main { // class to use us...