![]() |
aGrUM
0.20.3
a C++ library for (probabilistic) graphical models
|
Class representing a variable ( a column ) of a linear program, i.e. More...
#include <agrum/CN/LpInterface.h>
Public Member Functions | |
unsigned int | id () const |
Variable id accessor. More... | |
std::string | toString () const |
Get the string representation of a calling variable. More... | |
Constructor / Destructor | |
LpCol (unsigned int id) | |
Default constructor. More... | |
LpCol (const LpCol &col) | |
Default copy constructor. More... | |
~LpCol () | |
Default destructor. More... | |
Operators overload | |
bool | operator< (const LpCol &col) const |
Test of ordering < between two variables. More... | |
bool | operator== (const LpCol &col) const |
Test of equality == between two variables. More... | |
bool | operator!= (const LpCol &col) const |
Opposite of equality != test between two variables. More... | |
LpCol & | operator= (const LpCol &col) |
Assignment operator = by copy. More... | |
std::ostream & | operator<< (std::ostream &out, const LpCol &col) |
Overload of << to use with output streams ( such as std::cout << ). More... | |
Class representing a variable ( a column ) of a linear program, i.e.
a dimension of the problem.
Definition at line 60 of file LpInterface.h.
|
explicit |
Default constructor.
class LpCol
id | The id of the variable. |
Definition at line 44 of file LpInterface.cpp.
gum::credal::lp::LpCol::LpCol | ( | const LpCol & | col | ) |
Default copy constructor.
col | The constant reference to the variable to copy. |
Definition at line 49 of file LpInterface.cpp.
gum::credal::lp::LpCol::~LpCol | ( | ) |
Default destructor.
Definition at line 54 of file LpInterface.cpp.
unsigned int gum::credal::lp::LpCol::id | ( | ) | const |
Variable id accessor.
Opposite of equality !=
test between two variables.
For use with maps, hashTable etc
col | The constant reference to the variable to compare to this ( the caller ). |
True
if this id is not the same than col
id, false otherwise. Test of ordering <
between two variables.
For use with maps, hashTable etc
col | The constant reference to the variable to compare to this ( the caller ). |
True
if this id is smaller than col
id, false otherwise. Assignment operator =
by copy.
col | The constant reference to the variable to copy in this ( the caller ). |
Test of equality ==
between two variables.
For use with maps, hashTable etc
col | The constant reference to the variable to compare to this ( the caller ). |
True
if this id is equals to col
id, false otherwise. std::string gum::credal::lp::LpCol::toString | ( | ) | const |
Get the string representation of a calling variable.
|
friend |
Overload of <<
to use with output streams ( such as std::cout << ).
out | The reference to the caller, i.e. left side of << . |
col | The constant reference to the variable whose representation we want. |
|
private |
Variable id.
Definition at line 161 of file LpInterface.h.