Return to Snippet

Revision: 36240
at November 19, 2010 20:37 by trusktr


Initial Code
import java.util.*;

public class SalariedEmployee extends Employee {
	
	// Data Objects (
		public Number salary;
//  )
	// Constructors (
		public SalariedEmployee() {
			super();
			salary = new Number(0);
		}
		public SalariedEmployee(String f, String l, double sal) {
			super(f, l);
			salary = new Number(sal);
		}
		public SalariedEmployee(MyString f, MyString l, Number sal) {
			super(f, l);
			salary = new Number(sal);
		}
		public SalariedEmployee(EmployeeData d) {
			super(d);
			salary = new Number(0);
		}
		public SalariedEmployee(SalariedEmployee e) {
			super(e.info());
			salary = new Number(salary());
		}
//  )
	// Accessors (
//  )
	// Mutators (
		public Number salary() {
			return new Number(salary);
		}
		public Number grossPay() {
			return salary();
		}
//  )
}

Initial URL


Initial Description


Initial Title
cisp401 SalariedEmployee.java

Initial Tags


Initial Language
Java