Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #pragma once
- #include <string>
- namespace Records
- {
- const int DefaultStartingSalary{30'000};
- const int DefaultRaiseAndDemeritAmount{1'000};
- class Employee
- {
- public:
- Employee(const std::string &firstName, const std::string &lastName);
- void promote(int raiseAmount = DefaultRaiseAndDemeritAmount);
- void demote(int demeritAmount = DefaultRaiseAndDemeritAmount);
- void hire();
- void fire();
- void display() const;
- void setFirstName(const std::string &firstName);
- const std::string &getFirstName() const;
- void setLastName(const std::string &lastName);
- const std::string &getLastName() const;
- void setEmployeeNumber(int employeeNumber);
- int getEmployeeNumber() const;
- void setSalary(int newSalary);
- int getSalary() const;
- bool isHired() const;
- private:
- std::string m_firstName;
- std::string m_lastName;
- int m_employeeNumber;
- int m_salary;
- bool m_hired;
- };
- } // namespace Records
Advertisement
Add Comment
Please, Sign In to add comment