NPR Mid-Term Project Report: Multi-Client Chat Application Using TCP Java Socket
NPR Mid-Term Project Report: Multi-Client Chat Application Using TCP Java Socket
1. Project description:
In this project, we aimed to provide 2 applications which using TCP/IP socket method. The
applications are developed with GUI of both Server Application & Client Application. Those
applications complete following objectives:
Diagram
PROJECT IMPROVEMENT:
Change Enter button from inserting line break to instantly sending a message, now both
Send Button from the GUI, and Enter short key have event to send a message.
The line break now will be changed to the combination of keys Alt + Enter.
This change was advised by teacher to improve user experience.
2. Results:
2.1 Server
Server is used to set up server, in this project we used the default port 9090 and IP Address
which is localhost address:
In Server, it has a button which to start server. It is easy to execute since it is one-click away.
Server must be start to let user access to.
In Server, it has a Tabbed Pane which to show the message of client who sent message to server.
When client connect to the server, Server will automatically create a tab which is used show a
chat panel. And that client will enable to communicate with server privately.
Show the tab panel for the server to know who he/she communicate to right that moment
Status display whether server running or stop
Server GUI
Started ServerGUI
Waiting for client
Client Application displays the chat section for the user to communicate with the server app. We
also used the same default port and IP address (which are the same with Server) so when
Connect button is clicked the client application will establish a connection with a server
application.
Client Interface
Successfully connect to the server
3. Conclusion
Java sockets are quite useful in a variety of programming domains; this project is only one
example of their use. Despite the fact that it is only a simple chat application, we can show to the
java socket's efficiency in today's programming approaches.