/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* AForm.hpp :+: :+: :+: */ /* +:+ +:+ +:+ */ /* By: mmoussou void _log(std::string emoji, std::string what, std::string who, std::string str); typedef unsigned char uint8_t; #include "Bureaucrat.hpp" class AForm { public: AForm(void); AForm(std::string name, uint8_t minForSign, uint8_t minForExec); AForm(const AForm &); ~AForm(void); AForm &operator=(const AForm &); class GradeTooHighException : public std::exception { public: virtual const char *what() const throw(); }; class GradeTooLowException : public std::exception { public: virtual const char *what() const throw(); }; class NotSigned : public std::exception { public: virtual const char *what() const throw(); }; std::string getName(void) const; bool getSigned(void) const; uint8_t getMinForSign(void) const; uint8_t getMinForExec(void) const; void execute(const Bureaucrat &) const; void beSigned(Bureaucrat); private: std::string _name; bool _signed; const uint8_t _minForSign; const uint8_t _minForExec; void _gradeCheck(void) const; virtual void _exec(const Bureaucrat &) const = 0; }; std::ostream &operator<<(std::ostream &, AForm &);