00001
00002
00003
00004
00005
00006
00007
00008
00009 #ifndef __libutilxx__sella__variant__Unsigned_H__
00010 #define __libutilxx__sella__variant__Unsigned_H__
00011
00012 #include "../../common.h"
00013 #include "TypeCastException.h"
00014 #include "Nullable.h"
00015
00016 #include <memory>
00017
00018 #include <boost/regex.hpp>
00019
00020 namespace sella {
00021 namespace variant {
00022 class Unsigned;
00023 }
00024 }
00025
00026 class sella::variant::Unsigned : public Nullable {
00027 public:
00028 static const boost::regex Pattern;
00029 static const int Type = 0x04;
00030
00031
00032 Unsigned() throw ();
00033 Unsigned(const std::string &value) throw (TypeCastException);
00034 Unsigned(uint64_t value) throw ();
00035
00036 Unsigned(const Unsigned &other) throw ();
00037 virtual ~Unsigned() throw ();
00038
00039
00040 bool operator==(const Unsigned &other) const throw ();
00041 bool operator!=(const Unsigned &other) const throw ();
00042 bool operator>(const Unsigned &other) const throw ();
00043 bool operator<(const Unsigned &other) const throw ();
00044 bool operator!() throw ();
00045 Unsigned& operator=(const Unsigned &other) throw ();
00046 Unsigned& operator++() throw ();
00047 Unsigned& operator--() throw ();
00048 Unsigned& operator+=(uint64_t value) throw ();
00049 Unsigned& operator-=(uint64_t value) throw ();
00050 Unsigned& operator*=(uint64_t value) throw ();
00051 Unsigned& operator/=(uint64_t value) throw ();
00052 Unsigned& operator^=(uint64_t value) throw ();
00053 Unsigned& operator%=(uint64_t value) throw ();
00054 Unsigned& operator&=(uint64_t value) throw ();
00055 Unsigned& operator|=(uint64_t value) throw ();
00056 Unsigned& operator<<=(int bits) throw ();
00057 Unsigned& operator>>=(int bits) throw ();
00058
00059
00060 const uint64_t* getUnsigned() const throw (UnsupportedOperatorException);
00061
00062 virtual const std::string& str() const throw ();
00063 };
00064
00065 #endif
00066
00067
00068
00069