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
8
class
Worker
:
public
Employee
9
{
10
public
:
16
Worker
(
const
std::string& name,
float
hours,
float
wageHours);
18
~Worker
()
override
;
19
23
void
print
(std::ostream& s)
const override
;
24
28
float
payment
()
const override
29
{
return
_hours*_wageHours ; }
30
protected
:
31
private
:
32
float
_hours;
33
float
_wageHours;
34
};
35
Employee
Definition
employee.h:8
Worker
Definition
worker.h:9
Worker::payment
float payment() const override
Definition
worker.h:28
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 Fri May 22 2026 14:43:19 for Class Hierarchy by
1.9.8