School of Engineering and Applied Science
Department of Computer Science
CSci 53 -- Introduction to Software Development
http://www.seas.gwu.edu/~csci53/spring03
Prof. Michael B. Feldman
mfeldman@gwu.edu

Project 7
Due Date: beginning of lecture, Thursday, April 10, 2003

The goal of this project is to continue with development of your own classes.

Project:

In this project you will develop a Java class of your own, and modify and test one from the program library. The results of this project will be used in the next (and final) project of the course..

Part 1:

Copy and compile programs53/ShowInputLoop.java, which demonstrates robust integer input. Examine this program to make sure you understand it.

Robust input of numerical values is a very common need in software development. It therefore makes sense to take the ideas used in ShowInputLoop and build them into a class that provides robust input methods. The file programs53/RobustInput.java provides a skeleton for such a class, with the method bodies "stubbed out". Here is the description of the integer method:

  /**
  * Reads an integer value from keyboard, robustly.
  * The calling program provides minimum and maximum values;
  * the method prompts for a value in that range, then displays
  * an error message and loops  if the input value is not an
  * integer, or is out of range. Once a valid value is entered.
  * that value is returned to the calling program.
  */

In this part of the project you will complete and test the two input methods.

Part 2:

Section 4.5 of the textbook discusses a Java class called Student which uses another class Address. (The source files are, of course, in programs53.) In this part of the project, you are going to modify the Student class as follows. Develop a test plan for this revised student class, and a test program that carries out your plan. Document your RobustInput and Student classes with javadoc.

What to submit

You must follow the process given in Systematic Software Development and the sample project packet distributed in class.

Your grade will be calculated on a 20-point basis, as follows:

Extra credit:

We'll continue the 2-point bonus for getting an early start. If you e-mail your "framework" listing file for the Part 2 test program to Prof. Feldman, and the time stamp on the e-mail is no later than 5 PM, Monday, Apr. 7, 2003, you will be awarded 2 extra project points. The "framework" must be a listing (.lis) file, with no compilation errors or warnings, that contains the declared variables, and a set of comments inserted for the main algorithm steps.

MBF 4/1/03