1 #ifndef CPPAD_CG_VARIABLE_INCLUDED 2 #define CPPAD_CG_VARIABLE_INCLUDED 24 return node_->getCodeHandler();
31 return node_ !=
nullptr;
36 return node_ ==
nullptr;
41 return value_ !=
nullptr;
46 if (!isValueDefined()) {
47 throw CGException(
"No value defined for this variable");
55 if (value_ !=
nullptr) {
58 value_.reset(
new Base(b));
86 std::unique_ptr<Base>& value) {
88 value_ = std::move(value);
const Base & getValue() const
void setValue(const Base &val)
bool IdenticalOne(const cg::CG< Base > &x)
bool IdenticalZero(const cg::CG< Base > &x)
bool isValueDefined() const
CodeHandler< Base > * getCodeHandler() const