aboutsummaryrefslogtreecommitdiff
path: root/week12/Exercise4/Manager.h
blob: eee8f9fed8aae8cdbc9977100a3667c084678796 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#pragma once
#include "Employee.h"
#include "Person.h"

class Manager : public Person, public Employee {
	Person* manages;
	unsigned size;
	unsigned allocated;

	void resize();

	void free();
	void copyFrom(const Manager& other);

public:
	Manager();
	~Manager();
	Manager(const Manager& other);
	Manager& operator=(const Manager& other);
	Manager(Manager&& other);
	Manager& operator=(Manager&& other);

	void StartManaging(Person& newEmp);
	void StopManaging(const Person& oldEmp);

	virtual float Workload() override;
};