![]() |
Qore Programming Language - C/C++ Library 2.2.0
|
#include <qore/AbstractQoreNode.h>Go to the source code of this file.
Macros | |
| #define | HARD_QORE_VALUE_BINARY(list, i) |
| returns a const BinaryNode* from a hard typed binary param | |
| #define | HARD_QORE_VALUE_BOOL(list, i) |
| returns a bool from a hard typed bool param | |
| #define | HARD_QORE_VALUE_DATE(list, i) |
| returns a const DateTimeNode* from a hard typed date param | |
| #define | HARD_QORE_VALUE_FLOAT(list, i) |
| returns a double from a hard typed float param | |
| #define | HARD_QORE_VALUE_HASH(list, i) |
| returns a const QoreHashNode* from a hard typed hash param | |
| #define | HARD_QORE_VALUE_INT(list, i) |
| returns an int64 from a hard typed int param | |
| #define | HARD_QORE_VALUE_LIST(list, i) |
| returns a const QoreListNode* from a hard typed list param | |
| #define | HARD_QORE_VALUE_NUMBER(list, i) |
| returns a const QoreNumberNode* from a hard typed number or softnumber param | |
| #define | HARD_QORE_VALUE_OBJ_DATA(vname, Type, list, i, cid, dname, cname, xsink) |
| sets up an object pointer | |
| #define | HARD_QORE_VALUE_OBJ_OR_NOTHING_DATA(vname, Type, list, i, cid, xsink) |
| sets up an object pointer | |
| #define | HARD_QORE_VALUE_OBJECT(list, i) |
| returns a QoreObject* from a hard typed object param | |
| #define | HARD_QORE_VALUE_OR_NOTHING_PARAM(name, Type, list, i) |
| returns a hard typed parameter | |
| #define | HARD_QORE_VALUE_PARAM(name, Type, list, i) |
| returns a hard typed parameter | |
| #define | HARD_QORE_VALUE_REF(list, i) |
| returns a const QoreHashNode* from a hard typed hash param | |
| #define | HARD_QORE_VALUE_STRING(list, i) |
| returns a const QoreStringNode* from a hard typed string param | |
| #define | TAKE_HARD_QORE_VALUE_OBJ_DATA(vname, Type, list, i, cid, dname, cname, xsink) |
| destructively sets up an object pointer; caller owns the pointer | |
Functions | |
| template<typename T> | |
| static T * | get_hard_value_or_nothing_param (const QoreListNode *n, size_t i) |
| returns the given type for hard typed parameters | |
| static QoreValue | get_hard_value_param (const QoreListNode *n, size_t i) |
| returns the given type for hard typed parameters | |
| static QoreValue | get_param_value (const QoreListNode *n, size_t i) |
| returns the argument in the position given or 0 if there is none | |
| static const QoreEncoding * | get_value_encoding_param (const QoreListNode *n, size_t i, const QoreEncoding *def=QCS_DEFAULT) |
| returns the QoreEncoding corresponding to the string passed or a default encoding | |
| static unsigned | num_args (const QoreListNode *n) |
| returns the number of arguments passed to the function | |
| static unsigned | num_params (const QoreListNode *n) |
| returns the number of arguments passed to the function | |
| static const ReferenceNode * | test_reference_param (const QoreListNode *n, size_t i) |
| returns a ReferenceNode pointer for the argument position given or 0 if there is no argument there or if the argument is not a ReferenceNode | |
Contains inline functions for accessing function and class method arguments.
|
inlinestatic |
returns the argument in the position given or 0 if there is none
| n | a pointer to the argument list |
| i | the offset in the list to test (first element is offset 0) |
References QoreListNode::retrieveEntry().
|
inlinestatic |
returns the number of arguments passed to the function
| n | a pointer to the argument list |
References QoreListNode::size().
|
inlinestatic |
returns the number of arguments passed to the function
| n | a pointer to the argument list |
References QoreListNode::size().
Referenced by QoreClass::addAbstractMethod(), QoreNamespace::addBuiltinVariant(), QoreNamespace::addBuiltinVariant(), QoreClass::addConstructor(), QoreClass::addMethod(), and QoreClass::addStaticMethod().
|
inlinestatic |
returns a ReferenceNode pointer for the argument position given or 0 if there is no argument there or if the argument is not a ReferenceNode
Note that this will also return a value for a closure; this is a synonym for test_funcref_param
| n | a pointer to the argument list |
| i | the offset in the list to test (first element is offset 0) |
References QoreSimpleValue::get(), QoreSimpleValue::getType(), NT_REFERENCE, and QoreListNode::retrieveEntry().