![]() |
Positive infinity for built-in data types.The Infinity class is a wrapper class around the functionality of the blaze::Limits class to provide the possiblity to assign a positive infinity value to built-in data types. As positive infinity value, the largest possible positive value of the corresponding data type is used. In order to assign the positive infinity value, the Infinity class can be implicitly converted to the following 13 built-in integral and floating point data types: More...
#include <Infinity.h>
Public Types | |
typedef NegativeInfinity < Infinity > | NegativeType |
The negative infinity type. | |
Public Member Functions | |
Constructor | |
Infinity () | |
The default constructor of the Infinity class. | |
Conversion operators | |
operator unsigned char () const | |
Conversion operator to the unsigned char built-in type. More... | |
operator signed char () const | |
Conversion operator to the signed char built-in type. More... | |
operator char () const | |
Conversion operator to the char built-in type. More... | |
operator wchar_t () const | |
Conversion operator to the wchar_t built-in type. More... | |
operator unsigned short () const | |
Conversion operator to the unsigned short built-in type. More... | |
operator short () const | |
Conversion operator to the short built-in type. More... | |
operator unsigned int () const | |
Conversion operator to the unsigned int built-in type. More... | |
operator int () const | |
Conversion operator to the int built-in type. More... | |
operator unsigned long () const | |
Conversion operator to the unsigned long built-in type. More... | |
operator long () const | |
Conversion operator to the long built-in type. More... | |
operator float () const | |
Conversion operator to the float built-in type. More... | |
operator double () const | |
Conversion operator to the double built-in type. More... | |
operator long double () const | |
Conversion operator to the long double built-in type. More... | |
Arithmetic operators | |
const Infinity & | operator+ () const |
Returns the positive infinity value for all built-in data types. More... | |
const NegativeType | operator- () const |
Returns the negative infinity value for all built-in data types. More... | |
Utility functions | |
template<typename T > | |
bool | equal (const T &rhs) const |
Equality comparison to a built-in data type. More... | |
Private Member Functions | |
Forbidden operations | |
Infinity & | operator= (const Infinity &inf) |
Copy assignment operator (private & undefined) | |
void * | operator& () const |
Address operator (private & undefined) | |
Positive infinity for built-in data types.
The Infinity class is a wrapper class around the functionality of the blaze::Limits class to provide the possiblity to assign a positive infinity value to built-in data types. As positive infinity value, the largest possible positive value of the corresponding data type is used. In order to assign the positive infinity value, the Infinity class can be implicitly converted to the following 13 built-in integral and floating point data types:
In order to be able to assign infinity values, the global Infinity instance blaze::inf is provided, which can be used wherever a built-in data type is required.
|
inline |
Equality comparison to a built-in data type.
This function compares built-in data types with their largest possible value. The function only works for built-in data types. The attempt to compare user-defined class types will result in a compile time error.
|
inline |
Conversion operator to the char built-in type.
The conversion operator returns the largest possible char value.
|
inline |
Conversion operator to the double built-in type.
The conversion operator returns the largest possible double value.
|
inline |
Conversion operator to the float built-in type.
The conversion operator returns the largest possible float value.
|
inline |
Conversion operator to the int built-in type.
The conversion operator returns the largest possible int value.
|
inline |
Conversion operator to the long built-in type.
The conversion operator returns the largest possible long value.
|
inline |
Conversion operator to the long double built-in type.
The conversion operator returns the largest possible long double value.
|
inline |
Conversion operator to the short built-in type.
The conversion operator returns the largest possible short value.
|
inline |
Conversion operator to the signed char built-in type.
The conversion operator returns the largest possible signed char value.
|
inline |
Conversion operator to the unsigned char built-in type.
The conversion operator returns the largest possible unsigned char value.
|
inline |
Conversion operator to the unsigned int built-in type.
The conversion operator returns the largest possible unsigned int value.
|
inline |
Conversion operator to the unsigned long built-in type.
The conversion operator returns the largest possible unsigned long value.
|
inline |
Conversion operator to the unsigned short built-in type.
The conversion operator returns the largest possible unsigned short value.
|
inline |
Conversion operator to the wchar_t built-in type.
The conversion operator returns the largest possible wchar_t value.
|
inline |
Returns the positive infinity value for all built-in data types.
|
inline |
Returns the negative infinity value for all built-in data types.