- Upvotes Received
- 0
- Posts with Upvotes
- 0
- Upvoting Members
- 0
- Downvotes Received
- 1
- Posts with Downvotes
- 1
- Downvoting Members
- 1
I've got two threads running, one of them executes the following piece of code (it reads and writes to a socket): [CODE] while ((fromServer = in.readLine()) != null) { System.out.println(fromServer); fromUser = stdIn.readLine(); if (fromUser != null) { out.println(fromUser); } else{ break; } }[/CODE] where in and out are BufferedReader … |
|
I'm trying to write an instant messaging program in Java. What I have coded so far, goes like this: Each client connects to a thread created by the server, to which he/she sends the message. My doubt is, how can I kill all the threads that have been created by … |
|
I've got the following question about threads in Java: Isn't there a problem if: -There's a main program which creates a series of threads. Each thread needs to have access (and to modify) to the same object of a user defined class, and this object has references to a hashtable … |
|
Hola a todos, Estoy tratando de escribir un servidor de mensajería entre clientes, en Java. El problema que tengo es cuando quiero terminar el servidor. El servidor que he pensado funciona así: Cada cliente se conecta a un hilo que crea el servidor y allí envía los mensajes. El problema … |