Question: Develop a client/server application to view and add addresses, as shown in Figure 31.20. ? Use the StudentAddress class defined in Listing 31.5 to hold
Develop a client/server application to view and add addresses, as shown in Figure 31.20.
? Use the StudentAddress class defined in Listing 31.5 to hold the name, street, city, state, and zip in an object.? The user can use the buttons First, Next, Previous, and Last to view an address, and the Add button to add a new address.? Limit the concurrent connections to two clients.?
Name the client Exercise31_06Client and the server Exercise31_6Server.
Listing

Name John Smith Street 100 Main Street State GA Zip 31419 Savannah aty Previous Add Next Last First 1 public class StudentAddress implements java.io. Serializable { private String name; 3 private String street; 4 private String city; private String state; private String zip; 8. public StudentAddress(String name, String street, String city, String state, String zip) { this.name = name; this.street = street; this.city = city; this.state = state; this.zip = zip; 10 11 12 13 14 15 16 17 18 19 20 21 22 23 public String getName() { return name; public String getStreet () { return street; 24 public String getCity() { return city; 25 26 27 28 29 public String getState() { 30 return state; 31 32 33 public String getZip() { return zip; 34 { 36 } 35
Step by Step Solution
3.50 Rating (160 Votes )
There are 3 Steps involved in it
Program Plan Create class StudentAddress which defines structure for storing student address Create class Exercise3106Server which is the server for storing address and sending it on request Create cl... View full answer
Get step-by-step solutions from verified subject matter experts
