Class Hierarchy
Loading...
Searching...
No Matches
worker.h
Go to the documentation of this file.
1
#pragma once
2
3
#include "
employee.h
"
4
#include <iostream>
5
#include <string>
6
9
class
Worker
:
public
Employee
10
{
11
public
:
17
Worker
(
const
std::string& name,
float
hours,
float
wageHours);
19
~Worker
()
override
;
20
24
void
print
(std::ostream& s)
const override
;
25
29
float
payment
()
const override
30
{
return
_hours*_wageHours ; }
31
protected
:
32
private
:
33
float
_hours;
34
float
_wageHours;
35
};
36
Employee
Definition
employee.h:9
Worker
Definition
worker.h:10
Worker::payment
float payment() const override
Definition
worker.h:29
Worker::~Worker
~Worker() override
Definition
worker.cpp:12
Worker::print
void print(std::ostream &s) const override
Definition
worker.cpp:17
employee.h
worker.h
Generated on Mon Mar 2 2026 15:46:28 for Class Hierarchy by
1.9.8