This is a Java chat application that allows clients to send and receive messages and files through a server. Socket programming was implemented in this project for it to work.
Server.java
is the Java file for the lone server of the chat application.- Client1 is the directory for the first client.
Client.java
is the Java file for the particular client. It shall have the same executable code as the file in the other Client directory.
- Client2 is the directory for the second client.
Client.java
is the Java file for the particular client. It shall have the same executable code as the file in the other Client directory.
- Once you have downloaded this repository,
cd
to the folder of this project. - While in the folder, enter
javac Server.java
in the command line interface (CLI) to compile the server file. - Now, enter
java Server
in the CLI. The set IP address (localhost) and port number (8080) should now be displayed on the CLI. - While the CLI in which the server is located is still running, open two new CLI's. The two new CLI's should
cd
until the directories Client1 and Client2, respectively, are met. - For both CLI's, enter
javac Client.java
to compile the two client files. - Again, for both CLI's, enter
java Client
to run the two client files. In your desktop, two GUI windows should now appear. - The GUI windows will ask for three things: IP address, port number, and username. Input accordingly to the details indicated in the server's CLI. Username at your own discretion, as long as it's not empty. The GUI will keep asking if: (1) The inputted IP address and port number are wrong, or (2) There are empty areas.
- If all details are complete and correct, the application automatically redirects you to the chatroom. You may now start using De La Salle Usap!
- This is in partial fulfillment of the course Introduction to Computer Networks (CSNETWK).