diff options
Diffstat (limited to 'includes/BigInt.h')
-rw-r--r-- | includes/BigInt.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/includes/BigInt.h b/includes/BigInt.h index a94396c..ae5b0f7 100644 --- a/includes/BigInt.h +++ b/includes/BigInt.h @@ -12,6 +12,8 @@ class BigInt { BigInt(const BigInt &) throw (GeneralException); BigInt(BigInt &&); ~BigInt(); + template<class T> + BigInt(const T & v) : BigInt() { set(v); } BigInt & operator=(const BigInt &) throw (GeneralException); @@ -23,6 +25,11 @@ class BigInt { void set(const String &, int radix = 10) throw (GeneralException); void set2expt(int i) throw (GeneralException); + uint64_t to_uint64() const throw (GeneralException); + int64_t to_int64() const throw (GeneralException); + uint32_t to_uint32() const throw (GeneralException); + int32_t to_int32() const throw (GeneralException); + BigInt operator+(unsigned int) const throw (GeneralException); BigInt operator+(const BigInt &) const throw (GeneralException); BigInt operator-(unsigned int) const throw (GeneralException); |