AP Computer Science

Tuesday, March 28, 2006

Mon 3/27

Abstract classes, interfaces, inheritance

Tue 3/28

Programming project - p. 449 7.2

Make Employee abstract
Attributes (data members)
• name, id
Behaviors (methods)
• constructors
• get, set, toString
• abstract method --> work

Individual Employees extend Employee
• constructors use super
• override the work method
• override the toString method, but use
• super (see p. 398) output name and job
• create a few extra methods in extended classes
• e.g. Administrator has a department, get and set it
• Nurse has a number of patients
• main should have objects of each class as well as
• array of Employee(s)

Monday, March 20, 2006

Mon. 3/20

Review Ch. 6

Data redirection in the terminal

Short programs
-- p. 376 6.5, 6.6

Classwork
--p. 372-374 multiple choice all
--p. 375 TF all

Long programs
--p. 376 61, 6.4

FINISH AS HOMEWORK

Programming Test Fri. 3/17
Interfaces, static variables and methods,
classes, ArrayLists, typecasting

Chapter 5 programming
5.3, 5.4, 5.5

Marine Biology Case Study
--examine all of the private data members
--constructors and methods from Environment class

Library project
--Book class
--Library class
--Patron class