CS 5381 - Topics in Software Design HOMEWORK 4 (File $Date: 2008/02/28 05:27:44 $) Due: March 6, 2008 You may do this homework in a group of two. In this homework you will write a small Java application that allows one to query one's scores in a networked environment. For this you will use the C2 architectural style (see below). The key requirements of this application are: R1. The application consists of two programs, a server program and a client program that communicate with each other through TCP/IP sockets. R2. The server program stores information about students; for each student it stores the student's name, PIN, and scores. R3. The client program interacts with the user and the server program to retrieve and display the scores of a student. R4. The server program should send to the client program the scores of a student if and only if the client program supplies the correct PIN of the student. R5. The server program should be able to serve multiple clients simultaneously. (1) Use the C2 architectural style to define an architecture for the above application. Identify components, connectors, and the configuration. For each component, - Define precisely the set of messages (requests and notifications) that it sends to and is willing to receive from its top and bottom ports, and - Describe its behavior briefly in terms of the messages that it sends and receives. For each connector, - Define precisely the set of messages that it routes and broadcasts, and - Describe its behavior briefly in terms of its message routing and broadcasting. (2) Based on your architecture above, implement the application in Java. Organize your components and connectors into class hierarchies by identifying common interfaces and factoring out common code to (abstract) superclasses. In C2, each component is recommended to an internal architecture consisting of three elements: domain translator, dialog and constraints, and wrapper. Follow this guideline when you implement your components; however, not all components may need such an internal structure. WHAT AND HOW TO TURN IN Submit your programs, test outputs, and any supporting documents through the Assignment Submission page found in the Homework section of the course website. The page will ask you to zip, jar, or tar your programs, and upload a single file. The zip (jar or tar) file should include only a single directory named YourFirstNameLastName which contains all your source code files and other support files needed to compile and run your program; DO NOT INCLUDE BYTECODE (.class) FILES OR HTML FILES. You should submit your programs before the class time on the due date. No late submissions will be accepted unless arrangements have been made in advance or unless unusual circumstances warrant an exception. GRADING Clarity is important; if your writing or code is sloppy or hard to read, you will lose points.