diff options
Diffstat (limited to 'cpp02/ex00/Fixed.hpp')
| -rw-r--r-- | cpp02/ex00/Fixed.hpp | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/cpp02/ex00/Fixed.hpp b/cpp02/ex00/Fixed.hpp index e69de29..1f956d7 100644 --- a/cpp02/ex00/Fixed.hpp +++ b/cpp02/ex00/Fixed.hpp @@ -0,0 +1,33 @@ +/* ************************************************************************** */ +/* */ +/* ::: :::::::: */ +/* Fixed.hpp :+: :+: :+: */ +/* +:+ +:+ +:+ */ +/* By: charles <charles.cabergs@gmail.com> +#+ +:+ +#+ */ +/* +#+#+#+#+#+ +#+ */ +/* Created: 2020/04/13 11:40:49 by charles #+# #+# */ +/* Updated: 2020/04/13 11:53:30 by charles ### ########.fr */ +/* */ +/* ************************************************************************** */ + +#ifndef FIXED_HPP +# define FIXED_HPP + +# include <iostream> + +class Fixed +{ +public: + Fixed(); + Fixed(Fixed const& other); + ~Fixed(); + void operator=(Fixed const& other); + int getRawBits() const; + void setRawBits(int const raw); + +private: + int m_value; + static int const m_fractional_bits = 8; +}; + +#endif |
