59ffbd0bab538c80a6b6f82f3ab094089fa7f7d1
1 import java
.util
.concurrent
.ThreadLocalRandom
;
4 public class ThreadClientSend
implements Runnable
{
5 private SocketClient client
;
7 ThreadClientSend(SocketClient c
) {
12 BufferedReader userInput
= null;
14 userInput
= new BufferedReader(new InputStreamReader(System
.in
));
17 String line
= userInput
.readLine();
18 if (line
.equals(".")) {
22 System
.out
.println(Thread
.currentThread().getName() + " a envoye " + line
);
25 catch (IOException e
) {
26 System
.err
.println("IOException: " + e
);
30 if (userInput
!= null) {
34 catch (IOException e
) {
35 System
.err
.println("IOException: " + e
);