Assignment 4: SCorTrap Implementation
CISC 323, Winter 2006
Queen's University, Kingston, Ontario

This Assignment is due by noon on Tuesday, March 21.
Please make sure you have read the general Assignment Policies for CISC 323 before beginning this assignment. Please note the following especially:

Important: For this assignment, we're also going to ask you to hand in a copy of your code electronically via WebCT. Detailed instructions will appear on WebCT well before the due date. Yes, that means we're asking for two copies of your code -- one printed on paper (for TAs to read and scribble on) and one on WebCT (for TAs to run). It's a small amount of extra bother for you, but it makes it possible for us to do a better job of marking. If we don't get both copies from you, we will deduct an administrative penalty.

Please print out a copy of the assignment cover sheet (Word or PDF), fill out the information, and attach it to your assignment.

Overview: You now have a design for SCorTrap, a simplified version of the CorTrap program. Your task in this assignment is to implement SCorTrap. If you're happy with the design you did for Assignment 3, you may implement that design. Your other alternative is to implement the sample design we have posted (see Assignment 3 sample solution). The bottom line is that you must hand in a GUI program that implements the requirements of SCorTrap. Following a detailed design (yours or ours) will make this task much easier.

If you choose to implement your own design, you must be sure that it fulfills all of the requirements for SCorTrap. If you're not sure about that, you can discuss your design with Prof. Lamb or else fall back on the sample design. Please don't plan on waiting until Assignment 3 is returned to start this assignment!

Java and Java Tools: Your program must be written in Java, version 1.3 or later. You may use only the standard Java API. I've been warned recently that JBuilder has some extra Swing-like classes that aren't standard, in particular some extra layout managers. You may not use these for this assignment. All of the Swing classes and methods used in class and mentioned on the Swing Summary are standard Java. If you use JBuilder to develop your program and have any doubts, try compiling and running it with another Java tool before handing it in.

If you'd like information about Java tools and how to download them for use at home, take a look at this Java Tools page.

Supplied Code: As promised, we're supplied part of the SCorTrap program: the database and the calculation engine. Download and unzip this file: Assn4Code.zip. It contains four Java classes (database, calculation engine, and two small classes used by the database). It also contains the initial database file (SCorTrapBackup.dat). You can read the code if you're curious, but you don't need to. Click here for complete documentation of these classes. You will notice that the calculation engine and the database each include a main method, so they can be run as standalone programs. This is a common practice to help with testing and debugging. We promised you a way to create researchers outside of SCorTrap; the main method of that database class provides this. It's not fancy and it doesn't do any error checking, but it will get the job done. It may also be useful in other ways while you're debugging your program.

Please use all the supplied code without change. Your program must work with these classes as supplied. If you are convinced you've found a bug in any of the classes, please tell us so we can fix it and distribute a corrected version. Don't bother to hand this code in; the TAs will have copies and you'd just be wasting paper and WebCT space. Hand in only the code that you write yourself.

Marking and Implementation Strategies: The cover sheet lists the requirements of the program and the points allocated to each requirement. We will be giving the TAs a test plan for determining whether your program meets each requirement. If you're worried about time, we suggest that you take note of the point values on the cover sheet. Start out by implementing the first few requirements, which are worth the majority of the points. Add additional requirements as time permits. You can get a good mark without finishing all of the requirements. Make sure that you make a backup copy of your program each time you get a new feature working; that way, you'll have a working program to fall back on if you get stuck on the next feature or run into the deadline.

Style: Two points of your mark will be awarded for your programming style. This means that your code must be well-organized and readable. It must be divided into methods in a sensible way; a good rule of thumb is that a method that takes much more than a page to print should be split up. Your code must be consistently indented. Variable names must be meaningful. Each method should be preceeded by a comment with a brief description of what the method does, what parameters it takes (if any) and what result it returns (if any). The example Swing programs on the web site are a good examples of what we consider adequate style.

Please be careful when printing your code that you don't have lines "wrapping around". This makes your code difficult to read and understand and will affect your style mark. Split up long statements into several lines, with the continuation lines indented below the first line of the statement. For example:

    theAnswer = longVariableName1 + longVariableName2
        + longVariableName3 + longVariableName4;

Back to CISC 323 Home Page


This page maintained by Margaret Lamb, Queen's University, Kingston, Ontario.  Last modified  write(modifieddate) l>