Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
|
#include <model.h>
Public Types | |
enum | Type { INT_VALUE , INT_INTERVAL , INT_LIST , DOMAIN_LIST , FLOAT_VALUE , FLOAT_INTERVAL , FLOAT_LIST , VAR_REF , VAR_REF_ARRAY , VOID_ARGUMENT } |
Public Member Functions | |
std::string | DebugString () const |
bool | IsVariable () const |
Returns true if the argument is a variable. | |
bool | HasOneValue () const |
int64_t | Value () const |
Returns the value of the argument. Does DCHECK(HasOneValue()). | |
bool | IsArrayOfValues () const |
bool | Contains (int64_t value) const |
int64_t | ValueAt (int pos) const |
Returns the value of the pos-th element. | |
Variable * | Var () const |
Variable * | VarAt (int pos) const |
bool | HasOneValueAt (int pos) const |
Returns true is the pos-th argument is fixed. | |
int | Size () const |
Returns the number of object in the argument. | |
Static Public Member Functions | |
static Argument | IntegerValue (int64_t value) |
--— Argument --— | |
static Argument | Interval (int64_t imin, int64_t imax) |
static Argument | IntegerList (std::vector< int64_t > values) |
static Argument | DomainList (std::vector< Domain > domains) |
static Argument | FloatValue (double value) |
static Argument | FloatInterval (double lb, double ub) |
static Argument | FloatList (std::vector< double > floats) |
static Argument | VarRef (Variable *var) |
static Argument | VarRefArray (std::vector< Variable * > vars) |
static Argument | VoidArgument () |
static Argument | FromDomain (const Domain &domain) |
Public Attributes | |
Type | type |
std::vector< int64_t > | values |
std::vector< Variable * > | variables |
std::vector< Domain > | domains |
std::vector< double > | floats |
An argument is either an integer value, an integer domain, a reference to a variable, or an array of variable references.
bool operations_research::fz::Argument::Contains | ( | int64_t | value | ) | const |
std::string operations_research::fz::Argument::DebugString | ( | ) | const |
|
static |
|
static |
|
static |
bool operations_research::fz::Argument::HasOneValue | ( | ) | const |
bool operations_research::fz::Argument::HasOneValueAt | ( | int | pos | ) | const |
|
static |
|
static |
|
static |
bool operations_research::fz::Argument::IsArrayOfValues | ( | ) | const |
bool operations_research::fz::Argument::IsVariable | ( | ) | const |
int operations_research::fz::Argument::Size | ( | ) | const |
int64_t operations_research::fz::Argument::Value | ( | ) | const |
int64_t operations_research::fz::Argument::ValueAt | ( | int | pos | ) | const |
Variable * operations_research::fz::Argument::Var | ( | ) | const |
Variable * operations_research::fz::Argument::VarAt | ( | int | pos | ) | const |
|
static |
std::vector<Domain> operations_research::fz::Argument::domains |
std::vector<double> operations_research::fz::Argument::floats |
std::vector<int64_t> operations_research::fz::Argument::values |
std::vector<Variable*> operations_research::fz::Argument::variables |