cpar.h Source File¶
|
API
|
cpar.h
156 virtual cObject *getOwner() const override; // note: cannot return cComponent* (covariant return type) due to declaration order
462 void parse(const char *text, const char *baseDirectory=nullptr, FileLine loc=FileLine(), bool resetEvalContext=true);
521 cPar& operator=(unsigned long long i) {return setIntValue(checked_int_cast<intval_t>(i, this));}
616 operator unsigned long long() const {return checked_int_cast<unsigned long long>(intValue(), this);}
Definition fileline.h:28
cPar & setStringValue(const char *s)
double doubleValueInUnit(const char *targetUnit) const
void operator=(const cPar &other)
cPar & setDoubleValue(double d)
virtual std::string unparse() const
cExpression * getExpression() const
cPar & setExpression(cExpression *e, cComponent *evalcontext=nullptr)
const char * getUnit() const
cPar & setXMLValue(cXMLElement *node)
bool isNumeric() const
cPar & setIntValue(intval_t l)
virtual cObject * getOwner() const override
cObject * objectValue() const
cPar & setValue(const cValue &value)
bool isSet() const
cPar & setBoolValue(bool b)
bool containsValue() const
bool isExpression() const
intval_t intValue() const
cPar & setObjectValue(cObject *object)
virtual std::string getSourceLocation() const
bool isMutable() const
const char * stringValue() const
virtual const char * getBaseDirectory() const
cProperties * getProperties() const
cValue getValue() const
Type getType() const
cXMLElement * xmlValue() const
bool isVolatile() const
virtual const char * getName() const override
static const char * getTypeName(Type t)
void parse(const char *text, const char *baseDirectory=nullptr, FileLine loc=FileLine(), bool resetEvalContext=true)
virtual void forEachChild(cVisitor *v) override
virtual std::string str() const override
bool isShared() const
double doubleValue() const
bool boolValue() const
std::string stdstringValue() const
A variant-like value class used during evaluating NED expressions.
Definition cvalue.h:48
Enables traversing the tree of (cObject-rooted) simulation objects.
Definition cvisitor.h:57
Represents an XML element in an XML configuration file.
Definition cxmlelement.h:76
Internal class that stores values for cPar objects.
Definition cparimpl.h:47
int64_t intval_t
Signed integer type which is guaranteed to be at least 64 bits wide. It is used throughout the librar...
Definition simkerneldefs.h:101
ToInt checked_int_cast(FromInt x, const char *errmsg=nullptr)
Safe integer cast: it throws an exception if in case of an overflow, i.e. when if the target type can...
Definition simutil.h:46
Generated on for API by