The sign class represents the value type composed by the set (-1, 0, 1) sign value type is a subset of the int value type. More...
#include <sign.hh>
Public Types | |
typedef Scalar< void > | category |
typedef int | enc |
FIXME Are these typedefs correct? | |
typedef int | equiv |
Define the equivalent type. | |
typedef sign | exact_t |
Public Member Functions | |
operator int () const | |
Conversion to an integer. | |
sign & | operator= (int i) |
Assignment from an integer. | |
sign (int i) | |
Constructor from an integer. | |
sign () | |
Constructor without argument. | |
int | val_ () const |
Return the value associated to the sign object. | |
sign (const mln::literal::zero_t &) | |
Constructors/assignments with literals. | |
sign & | operator= (const mln::literal::zero_t &) |
sign (const mln::literal::one_t &) | |
sign & | operator= (const mln::literal::one_t &) |
Static Public Attributes | |
static const sign | one = 1 |
Unit value. | |
static const sign | zero = 0 |
Zero value. | |
Protected Attributes | |
int | v_ |
The value. |
The sign class represents the value type composed by the set (-1, 0, 1) sign value type is a subset of the int value type.
typedef Scalar<void> mln::value::Scalar< sign >::category [inherited] |
Reimplemented from mln::Value< sign >.
typedef int mln::value::sign::enc |
FIXME Are these typedefs correct?
Define the encoding type
typedef int mln::value::sign::equiv |
Define the equivalent type.
typedef sign mln::Object< sign >::exact_t [inherited] |
mln::value::sign::sign | ( | ) | [inline] |
Constructor without argument.
mln::value::sign::sign | ( | int | i | ) | [inline] |
Constructor from an integer.
References v_.
mln::value::sign::sign | ( | const mln::literal::zero_t & | ) | [inline] |
Constructors/assignments with literals.
References v_.
mln::value::sign::sign | ( | const mln::literal::one_t & | ) | [inline] |
References v_.
mln::value::sign::operator int | ( | ) | const [inline] |
Conversion to an integer.
References v_.
sign & mln::value::sign::operator= | ( | const mln::literal::one_t & | ) | [inline] |
References v_.
sign & mln::value::sign::operator= | ( | const mln::literal::zero_t & | ) | [inline] |
References v_.
int mln::value::sign::val_ | ( | ) | const [inline] |
Return the value associated to the sign object.
References v_.
Referenced by mln::value::operator<(), mln::value::operator<<(), and mln::value::operator==().
const sign mln::value::sign::one = 1 [static] |
Unit value.
int mln::value::sign::v_ [protected] |
The value.
Referenced by operator int(), operator=(), sign(), and val_().
const sign mln::value::sign::zero = 0 [static] |
Zero value.