Question: Programming Language: JAVA Package name: exer2 in this package, create the classes ServerExer2 and ClientExer2 Add a directory file named res and add a text

 Programming Language: JAVA Package name: exer2 in this package, create the

Programming Language: JAVA Package name: exer2 in this package, create the classes ServerExer2 and ClientExer2 Add a directory file named res and add a text file name data. For every line of this file, it will contain a name and a corresponding age separated by a space. use this text file: Anthony Stark 32 Thor Odinson 27 Henry Pym 31 Robert Bruce 29 Steven Rogers 35 Clinton Barton 39 Pietro Maximoff 33 Luke Charles 20 Natasha Alianovna 21 Peter Parker 18 Objectives: Create a client program that reads each line of this input file and sends over the read data to the server. The server processes the data received and sends to the client machine a similar response as what is provided in the example program (see SampleServerl). The client machine should print the response coming from the server. If the client program can no longer read any data from the input file, it shall send the message "bye" to the server. Upon receiving the message "bye" from the client, the server will no longer process the data and terminates. The client, on the other hand, should not expect a response from the server and therefore stops executing. After successfully creating Server class and client class. Add another package named exer3. You are to create ServerExer3 class inside this package. This class should be a modification of the server program of ServerExer2 class. It should be able to accept as many clients as possible. Make the server to run "continuously and will stop executing only if the user will manually stop the server

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!