Results 1 to 2 of 2
Thread: User List + Other rooms
- 12-14-2009, 05:04 PM #1Member
- Join Date
- Dec 2009
- Rep Power
User List + Other rooms
I'm trying to create multiple chatrooms using tcp java. i have two questions, was wondering how i would be able to display the users in the room e.g. type a key word to display who is there.
The second thing is i want to make it so there is multiple rooms for the user to pick from how could i do these two things in the simplest way?
- 12-14-2009, 05:42 PM #2
I would model the room and the people chatting in the room as objects. Then you can pass people objects from client to client using object serialization. All the info about a client can be stored in the client object and retrieved by the other clients on the other end directly. When I implemented an IRC client/server, I kept the connected client list on the server and pushed it to each client as they connected. When a new user would connect or one would leave, I'd send a message to the server which then relayed a connect or disconnect message to each client.
- By nmvictor in forum New To JavaReplies: 2Last Post: 11-22-2009, 06:24 PM
- By nmvictor in forum New To JavaReplies: 3Last Post: 11-21-2009, 06:48 PM
- By ilayaraja in forum Advanced JavaReplies: 1Last Post: 10-26-2009, 05:30 PM
- By igniteflow in forum Advanced JavaReplies: 1Last Post: 12-10-2008, 09:53 PM
- By alvations in forum New To JavaReplies: 5Last Post: 10-08-2008, 12:23 PM