32 #ifndef _QORE_OBJECTMETHODREFERENCE_H
34 #define _QORE_OBJECTMETHODREFERENCE_H
38 class AbstractParseObjectMethodReferenceNode :
public ParseNode {
47 DLLLOCAL AbstractParseObjectMethodReferenceNode(
const QoreProgramLocation* loc) : ParseNode(loc,
NT_OBJMETHREF) {
50 DLLLOCAL
virtual ~AbstractParseObjectMethodReferenceNode() {
54 str.
sprintf(
"object method reference (%p)",
this);
62 getAsString(*rv, foff, xsink);
67 DLLLOCAL
virtual const char* getTypeName()
const {
68 return "object method reference";
72 class ParseObjectMethodReferenceNode :
public AbstractParseObjectMethodReferenceNode {
80 DLLLOCAL
virtual ~ParseObjectMethodReferenceNode();
82 DLLLOCAL
virtual const QoreTypeInfo* getTypeInfo()
const {
83 return callReferenceTypeInfo;
94 DLLLOCAL ParseObjectMethodReferenceNode(
const QoreProgramLocation* loc,
QoreValue n_exp,
char* n_method);
95 DLLLOCAL
virtual int parseInitImpl(
QoreValue& val, QoreParseContext& parse_context);
98 class ParseSelfMethodReferenceNode :
public AbstractParseObjectMethodReferenceNode {
103 DLLLOCAL ~ParseSelfMethodReferenceNode() {
106 DLLLOCAL
virtual int parseInitImpl(
QoreValue& val, QoreParseContext& parse_context);
108 DLLLOCAL
virtual const QoreTypeInfo* getTypeInfo()
const {
109 return callReferenceTypeInfo;
117 DLLLOCAL ParseSelfMethodReferenceNode(
const QoreProgramLocation* loc,
char* n_method)
118 : AbstractParseObjectMethodReferenceNode(loc), method(n_method), meth(0) {
122 DLLLOCAL ParseSelfMethodReferenceNode(
const QoreProgramLocation* loc,
const QoreMethod* m)
123 : AbstractParseObjectMethodReferenceNode(loc), meth(m) {
127 class ParseScopedSelfMethodReferenceNode :
public AbstractParseObjectMethodReferenceNode {
132 DLLLOCAL
virtual ~ParseScopedSelfMethodReferenceNode();
138 DLLLOCAL
virtual int parseInitImpl(
QoreValue& val, QoreParseContext& parse_context);
139 DLLLOCAL
virtual const QoreTypeInfo* getTypeInfo()
const {
140 return callReferenceTypeInfo;
144 DLLLOCAL ParseScopedSelfMethodReferenceNode(
const QoreProgramLocation* loc, NamedScope *n_nscope);
container for holding Qore-language exception information and also for registering a "thread_exit" ca...
Definition: ExceptionSink.h:48
defines a Qore-language class
Definition: QoreClass.h:249
a method in a QoreClass
Definition: QoreClass.h:135
Qore's string type supported by the QoreEncoding class.
Definition: QoreString.h:93
DLLEXPORT int sprintf(const char *fmt,...)
this will concatentate a formatted string to the existing string according to the format string and t...
provides a mutually-exclusive thread lock
Definition: QoreThreadLock.h:49
const qore_type_t NT_OBJMETHREF
type value for AbstractParseObjectMethodReferenceNode
Definition: node_types.h:67
The main value class in Qore, designed to be passed by value.
Definition: QoreValue.h:275