summaryrefslogtreecommitdiff
path: root/ex00
diff options
context:
space:
mode:
authorDominik Kaiser2025-02-13 12:51:25 +0100
committerDominik Kaiser2025-02-13 12:51:25 +0100
commit9aeae0c6e3d453cab20c0279747d6cb804d49a91 (patch)
tree8bae9e0b2c5a65bee4d7ca880c3c39768f1b8e98 /ex00
parentee43f487329ca1bc04ae25cc13b9d4e374bc1adb (diff)
downloadcpp02-9aeae0c6e3d453cab20c0279747d6cb804d49a91.tar.gz
cpp02-9aeae0c6e3d453cab20c0279747d6cb804d49a91.zip
Add Fixed class
Diffstat (limited to 'ex00')
-rw-r--r--ex00/Fixed.hpp17
1 files changed, 16 insertions, 1 deletions
diff --git a/ex00/Fixed.hpp b/ex00/Fixed.hpp
index 47d02cf..114905d 100644
--- a/ex00/Fixed.hpp
+++ b/ex00/Fixed.hpp
@@ -6,11 +6,26 @@
/* By: dkaiser <dkaiser@student.42heilbronn.de +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/02/12 17:05:34 by dkaiser #+# #+# */
-/* Updated: 2025/02/12 17:05:59 by dkaiser ### ########.fr */
+/* Updated: 2025/02/13 12:50:05 by dkaiser ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef FIXED_H_
#define FIXED_H_
+class Fixed
+{
+ public:
+ Fixed(void);
+ Fixed(const Fixed &other);
+ Fixed &operator=(const Fixed &other);
+ ~Fixed(void);
+
+ int getRawBits(void) const;
+ void setRawBits(int const raw);
+ private:
+ static const int fractional_bits = 8;
+ int value;
+}
+
#endif