// Fig. 9.5: hourly.h // Definition of class HourlyWorker #ifndef HOURLY_H #define HOURLY_H #include #include "Employee.h" using namespace std; class HourlyWorker : public Employee { public: HourlyWorker(const string &first, const string &last, double initHours = 0.0, double initWage = 0.0); void setHours(double initHours); void setWage(double initWage); double getPay() const; // calculate and return salary private: double wage; // wage per hour double hours; // hours worked for week }; // output first and last name and wages; // Note it is no longer const << can't be const ostream &operator<<(ostream&,const HourlyWorker&); #endif