Integer number.
More...
#include <Integer.h>
◆ Integer() [1/3]
TBTK::Integer::Integer |
( |
| ) |
|
|
inline |
◆ Integer() [2/3]
constexpr TBTK::Integer::Integer |
( |
int |
value | ) |
|
|
inlineconstexpr |
Constructor.
- Parameters
-
value | The value to initilize the Integer with. |
◆ Integer() [3/3]
Constructs an Index from a serialization string.
- Parameters
-
serialization | Serialization string from which to construct the Integer. |
mode | Mode with which the string has been serialized. |
◆ operator int()
constexpr TBTK::Integer::operator int |
( |
| ) |
const |
|
inlineconstexpr |
Type conversion operator.
◆ operator*=()
Multiplication assignment operator.
- Parameters
-
- Returns
- The Integer after the multiplication has occured.
◆ operator++() [1/2]
Integer& TBTK::Integer::operator++ |
( |
| ) |
|
|
inline |
Increment operator.
- Returns
- The Integer after the increment has occured.
◆ operator++() [2/2]
Integer TBTK::Integer::operator++ |
( |
int |
| ) |
|
|
inline |
Increment operator.
- Returns
- The Integer before the increment has occured.
◆ operator+=()
Addition assignment operator.
- Parameters
-
- Returns
- The Integer after the addition has occured.
◆ operator--() [1/2]
Integer& TBTK::Integer::operator-- |
( |
| ) |
|
|
inline |
Decrement operator.
- Returns
- The Integer after the decrease has occured.
◆ operator--() [2/2]
Integer TBTK::Integer::operator-- |
( |
int |
| ) |
|
|
inline |
Decrement operator.
- Returns
- The Integer before the decrease has occured.
◆ operator-=()
Subtraction assignment operator.
- Parameters
-
- Returns
- The Integer after the subtraction has occured.
◆ operator/=()
Division assignment operator.
- Parameters
-
- Returns
- The Integer after the division has occured.
◆ operator=()
Integer& TBTK::Integer::operator= |
( |
int |
rhs | ) |
|
|
inline |
Assignment operator.
- Parameters
-
value | The value to assign the Integer. |
- Returns
- The Integer after assignment has occured.
◆ serialize()
◆ from_json
void from_json |
( |
const nlohmann::json & |
j, |
|
|
Integer & |
integer |
|
) |
| |
|
friend |
Implements the Nlohmann json interface for conversion from json.
- Parameters
-
j | The json input. |
integer | The Integer to convert to. |
◆ to_json
void to_json |
( |
nlohmann::json & |
j, |
|
|
const Integer & |
integer |
|
) |
| |
|
friend |
Implements the Nlohmann json interface for conversion to json.
- Parameters
-
j | The json output. |
integer | The Integer to convert. |
The documentation for this class was generated from the following file: