| Qore Programming Language - C/C++ Library 0.9.14

QoreObject.h
1 /* -*- mode: c++; indent-tabs-mode: nil -*- */
2 /*
3 QoreObject.h
4
5 thread-safe object definition
6
7 Qore Programming Language
8
9 Copyright (C) 2003 - 2020 Qore Technologies, s.r.o.
10
11 Permission is hereby granted, free of charge, to any person obtaining a
12 copy of this software and associated documentation files (the "Software"),
13 to deal in the Software without restriction, including without limitation
14 the rights to use, copy, modify, merge, publish, distribute, sublicense,
15 and/or sell copies of the Software, and to permit persons to whom the
16 Software is furnished to do so, subject to the following conditions:
17
18 The above copyright notice and this permission notice shall be included in
19 all copies or substantial portions of the Software.
20
21 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24 AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
26 FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
27 DEALINGS IN THE SOFTWARE.
28
29 Note that the Qore library is released under a choice of three open-source
30 licenses: MIT (as above), LGPL 2+, or GPL 2+; see README-LICENSE for more
31 information.
32 */
33
34 #ifndef _QORE_QOREOBJECT_H
35
36 #define _QORE_QOREOBJECT_H
37
38 class AutoVLock;
39 class VRMutex;
40 class BuiltinCopy;
41 class BuiltinDeleteBlocker;
42 class BuiltinNormalMethodVariantBase;
43 class BuiltinCopyVariantBase;
44 class QoreExternalMethodVariant;
45 class QoreProgram;
46
48
61 class QoreObject : public AbstractQoreNode {
62 friend class qore_object_private;
63 friend class ObjectRSetHelper;
64 friend class ObjectRSet;
65 friend class qore_object_dereference_helper;
66
67 private:
69 class qore_object_private* priv;
70
72 DLLLOCAL QoreObject(const QoreObject&);
73
75 DLLLOCAL QoreObject& operator=(const QoreObject&);
76
77 protected:
79
83 DLLEXPORT virtual bool derefImpl(ExceptionSink* xsink);
84
86
88 DLLLOCAL virtual QoreValue evalImpl(bool& needs_deref, ExceptionSink* xsink) const;
89
91 DLLLOCAL virtual void customRef() const;
92
94 DLLLOCAL virtual void customDeref(ExceptionSink* xsink);
95
97 DLLLOCAL virtual ~QoreObject();
98
99 public:
101
105 DLLEXPORT QoreObject(const QoreClass* oc, QoreProgram* p);
106
108
113 DLLEXPORT QoreObject(const QoreClass* oc, QoreProgram* p, AbstractPrivateData* data);
114
116 DLLEXPORT bool hasMember(const char* mem, ExceptionSink* xsink) const;
117
119
121 DLLEXPORT virtual bool getAsBoolImpl() const;
122
124
130 DLLEXPORT virtual int getAsString(QoreString &str, int foff, ExceptionSink* xsink) const;
131
133
140 DLLEXPORT virtual QoreString* getAsString(bool& del, int foff, ExceptionSink* xsink) const;
141
143 DLLEXPORT virtual AbstractQoreNode* realCopy() const;
144
146
150 DLLEXPORT virtual bool is_equal_soft(const AbstractQoreNode* v, ExceptionSink* xsink) const;
151
153
157 DLLEXPORT virtual bool is_equal_hard(const AbstractQoreNode* v, ExceptionSink* xsink) const;
158
160 DLLEXPORT virtual const char* getTypeName() const;
161
163 DLLLOCAL static const char* getStaticTypeName() {
164 return "object";
165 }
166
168 DLLLOCAL static qore_type_t getStaticTypeCode() {
169 return NT_OBJECT;
170 }
171
173
177 DLLEXPORT bool validInstanceOf(qore_classid_t cid) const;
178
180
182 DLLEXPORT bool validInstanceOf(const QoreClass& qc) const;
183
185
190 DLLEXPORT void setValue(const char* key, QoreValue val, ExceptionSink* xsink);
191
193
196 DLLEXPORT QoreListNode* getMemberList(ExceptionSink* xsink) const;
197
199
203 DLLEXPORT void deleteMemberValue(const QoreString* key, ExceptionSink* xsink);
204
206
210 DLLEXPORT void deleteMemberValue(const char* key, ExceptionSink* xsink);
211
213
217 DLLEXPORT void removeMember(const QoreString* key, ExceptionSink* xsink);
218
220
224 DLLEXPORT void removeMember(const char* key, ExceptionSink* xsink);
225
227
232 DLLEXPORT QoreValue takeMember(const QoreString* key, ExceptionSink* xsink);
233
235
240 DLLEXPORT QoreValue takeMember(const char* key, ExceptionSink* xsink);
241
243
246 DLLEXPORT int size(ExceptionSink* xsink) const;
247
249
253 DLLEXPORT bool compareSoft(const QoreObject* obj, ExceptionSink* xsink) const;
254
256
260 DLLEXPORT bool compareHard(const QoreObject* obj, ExceptionSink* xsink) const;
261
263
268 DLLEXPORT QoreValue getReferencedMemberNoMethod(const char* mem, ExceptionSink* xsink) const;
269
271
277 DLLEXPORT int64 getMemberAsBigInt(const char* mem, bool& found, ExceptionSink* xsink) const;
278
280
283 DLLEXPORT QoreHashNode* copyData(ExceptionSink* xsink) const;
284
286
290 DLLEXPORT void setPrivate(qore_classid_t key, AbstractPrivateData* pd);
291
293
297 DLLEXPORT AbstractPrivateData* getReferencedPrivateData(qore_classid_t key, ExceptionSink* xsink) const;
298
300
306 DLLEXPORT AbstractPrivateData* tryGetReferencedPrivateData(qore_classid_t key, ExceptionSink* xsink) const;
307
309
314 DLLEXPORT QoreValue evalMethod(const QoreString* name, const QoreListNode* args, ExceptionSink* xsink);
315
317
322 DLLEXPORT QoreValue evalMethod(const char* name, const QoreListNode* args, ExceptionSink* xsink);
323
325
330 DLLEXPORT QoreValue evalMethod(const QoreMethod& method, const QoreListNode* args, ExceptionSink* xsink);
331
333
343 DLLEXPORT QoreValue evalMethod(const QoreMethod& method, const QoreClass* class_ctx, const QoreListNode* args, ExceptionSink* xsink);
344
346
349 DLLEXPORT void doDelete(ExceptionSink* xsink);
350
352
356 DLLEXPORT const QoreClass* getClass(qore_classid_t cid) const;
357
359
366 DLLEXPORT const QoreClass* getClass(qore_classid_t cid, bool& priv) const;
367
369
375 DLLEXPORT ClassAccess getClassAccess(const QoreClass& cls) const;
376
378
381 DLLEXPORT const QoreClass* getClass() const;
382
384
387 DLLEXPORT const char* getClassName() const;
388
390
393 DLLEXPORT bool isValid() const;
394
396
399 DLLEXPORT QoreProgram* getProgram() const;
400
402
405 DLLEXPORT bool isSystemObject() const;
406
408
413 DLLEXPORT void tRef() const;
414
416
419 DLLEXPORT void tDeref();
420
422 DLLEXPORT void realRef();
423
425 DLLEXPORT void realDeref(ExceptionSink* xsink);
426
428
436 DLLEXPORT QoreValue getMemberValueNoMethod(const QoreString* key, AutoVLock* vl, ExceptionSink* xsink) const;
437
439
445 DLLEXPORT QoreValue getMemberValueNoMethod(const char* key, AutoVLock* vl, ExceptionSink* xsink) const;
446
448
454 DLLEXPORT QoreValue getReferencedMemberNoMethod(const char* key, const QoreClass* cls, ExceptionSink* xsink) const;
455
457
466 DLLEXPORT int setMemberValue(const char* key, const QoreClass* cls, const QoreValue val, ExceptionSink* xsink);
467
469
471 DLLEXPORT void deleteBlockerRef() const;
472
474
478 DLLEXPORT void externalDelete(qore_classid_t key, ExceptionSink* xsink);
479
481 DLLEXPORT QoreValue evalMethodVariant(const QoreMethod& method, const QoreExternalMethodVariant* variant, const QoreListNode* args, ExceptionSink* xsink);
482
484
486 DLLEXPORT QoreValue evalMethodVariant(const QoreMethod& method, const QoreClass* class_ctx, const QoreExternalMethodVariant* variant, const QoreListNode* args, ExceptionSink* xsink);
487
489
491 DLLEXPORT static QoreValue evalStaticMethod(const QoreMethod& method, const QoreListNode* args, ExceptionSink* xsink);
492
494
496 DLLEXPORT static QoreValue evalStaticMethod(const QoreMethod& method, const QoreClass* class_ctx, const QoreListNode* args, ExceptionSink* xsink);
497
499
501 DLLEXPORT static QoreValue evalStaticMethodVariant(const QoreMethod& method, const QoreExternalMethodVariant* variant, const QoreListNode* args, ExceptionSink* xsink);
502
504
506 DLLEXPORT static QoreValue evalStaticMethodVariant(const QoreMethod& method, const QoreClass* class_ctx, const QoreExternalMethodVariant* variant, const QoreListNode* args, ExceptionSink* xsink);
507
509
515 DLLEXPORT QoreValue evalMember(const QoreString* member, ExceptionSink* xsink);
516
518
525 DLLEXPORT QoreValue evalMember(const char* member, ExceptionSink* xsink);
526
527 DLLLOCAL int getStatus() const;
528
529 DLLLOCAL class KeyNode* getReferencedPrivateDataNode(qore_classid_t key);
530
532
536 DLLLOCAL AbstractPrivateData* getAndClearPrivateData(qore_classid_t key, ExceptionSink* xsink);
537
539
545 DLLLOCAL QoreValue evalBuiltinMethodWithPrivateData(const QoreMethod& method, const BuiltinNormalMethodVariantBase* meth, const QoreListNode* args, ExceptionSink* xsink);
546
548 DLLLOCAL void evalCopyMethodWithPrivateData(const QoreClass &thisclass, const BuiltinCopyVariantBase* meth, QoreObject* self, ExceptionSink* xsink);
549
551
555 DLLLOCAL void addPrivateDataToString(QoreString* str, ExceptionSink* xsink) const;
556
558
561 DLLLOCAL void obliterate(ExceptionSink* xsink);
562
564
568 DLLLOCAL void defaultSystemDestructor(qore_classid_t classID, ExceptionSink* xsink);
569
570 // returns a new hash consisting of just the members of value_list
571 DLLLOCAL QoreHashNode* getSlice(const QoreListNode* value_list, ExceptionSink* xsink) const;
572
574 DLLLOCAL QoreObject(const QoreClass* oc, QoreProgram* p, QoreHashNode* d);
575
577 DLLLOCAL bool evalDeleteBlocker(qore_classid_t classid_for_method, BuiltinDeleteBlocker* meth);
578
580 DLLLOCAL bool hasMemberNotification() const;
581
583 DLLLOCAL void execMemberNotification(const char* member, ExceptionSink* xsink);
584 };
585
587 template <class T>
588 class PrivateDataRefHolder : public ReferenceHolder<T> {
589 public:
590 DLLLOCAL PrivateDataRefHolder(ExceptionSink* xsink) : ReferenceHolder<T>(xsink) {
591 }
592
593 DLLLOCAL PrivateDataRefHolder(const QoreObject* o, qore_classid_t cid, ExceptionSink* xsink) : ReferenceHolder<T>(reinterpret_cast<T*>(o->getReferencedPrivateData(cid, xsink)), xsink) {
594 }
595
597 DLLLOCAL void operator=(T *nv) {
598 if (this->p)
599 this->p->deref(this->xsink);
600 this->p = nv;
601 }
602 };
603
605 template <class T>
606 class TryPrivateDataRefHolder : public ReferenceHolder<T> {
607 public:
608 DLLLOCAL TryPrivateDataRefHolder(const QoreObject* o, qore_classid_t cid, ExceptionSink* xsink) : ReferenceHolder<T>(reinterpret_cast<T*>(o->tryGetReferencedPrivateData(cid, xsink)), xsink) {
609 }
610
612 DLLLOCAL void operator=(T *nv) {
613 if (this->p)
614 this->p->deref(this->xsink);
615 this->p = nv;
616 }
617 };
618
619 class QorePrivateObjectAccessHelper {
620 public:
621 DLLLOCAL QorePrivateObjectAccessHelper(ExceptionSink* xs) : xsink(xs), ptr(0) {
622 }
623
624 DLLLOCAL operator bool() const {
625 return (bool)ptr;
626 }
627
628 private:
629 DLLLOCAL QorePrivateObjectAccessHelper(const QorePrivateObjectAccessHelper&) = delete;
630 DLLLOCAL QorePrivateObjectAccessHelper& operator=(const QorePrivateObjectAccessHelper&) = delete;
631 DLLLOCAL void* operator new(size_t) = delete;
632
633 protected:
634 ExceptionSink* xsink;
635 void* ptr;
636 };
637
638 #endif
AbstractPrivateData
the base class for all data to be used as private data of Qore objects
Definition: AbstractPrivateData.h:44
AbstractQoreNode
The base class for all value and parse types in Qore expression trees.
Definition: AbstractQoreNode.h:54
AutoVLock
AutoVLock is a container for safely managing global variable and object lock handovers,...
Definition: AutoVLock.h:80
ExceptionSink
container for holding Qore-language exception information and also for registering a "thread_exit" ca...
Definition: ExceptionSink.h:48
PrivateDataRefHolder
convenience class for holding AbstractPrivateData references
Definition: QoreObject.h:588
PrivateDataRefHolder::operator=
DLLLOCAL void operator=(T *nv)
assigns a new pointer to the holder, dereferences the current pointer if any
Definition: QoreObject.h:597
QoreClass
defines a Qore-language class
Definition: QoreClass.h:239
QoreExternalMethodVariant
external wrapper class for method variants
Definition: QoreReflection.h:90
QoreHashNode
This is the hash or associative list container type in Qore, dynamically allocated only,...
Definition: QoreHashNode.h:50
QoreListNode
This is the list container type in Qore, dynamically allocated only, reference counted.
Definition: QoreListNode.h:52
QoreMethod
a method in a QoreClass
Definition: QoreClass.h:125
QoreObject
the implementation of Qore's object data type, reference counted, dynamically-allocated only
Definition: QoreObject.h:61
QoreObject::getReferencedPrivateData
DLLEXPORT AbstractPrivateData * getReferencedPrivateData(qore_classid_t key, ExceptionSink *xsink) const
returns the private data corresponding to the class ID passed with an incremented reference count,...
QoreObject::getTypeName
virtual DLLEXPORT const char * getTypeName() const
returns the type name as a c string
QoreObject::derefImpl
virtual DLLEXPORT bool derefImpl(ExceptionSink *xsink)
runs the destructor if necessary and dereferences all members
QoreObject::evalDeleteBlocker
DLLLOCAL bool evalDeleteBlocker(qore_classid_t classid_for_method, BuiltinDeleteBlocker *meth)
evaluates the delete blocker function for the managed private data
QoreObject::hasMemberNotification
DLLLOCAL bool hasMemberNotification() const
returns true if the class has a memberNotification method
QoreObject::tRef
DLLEXPORT void tRef() const
increments the existence reference count
QoreObject::evalBuiltinMethodWithPrivateData
DLLLOCAL QoreValue evalBuiltinMethodWithPrivateData(const QoreMethod &method, const BuiltinNormalMethodVariantBase *meth, const QoreListNode *args, ExceptionSink *xsink)
called to evaluate a builtin method when private data is available
QoreObject::compareSoft
DLLEXPORT bool compareSoft(const QoreObject *obj, ExceptionSink *xsink) const
tests for equality ("deep compare" including all contained values) with possible type conversion of c...
QoreObject::customRef
virtual DLLLOCAL void customRef() const
custom reference handler
QoreObject::evalMember
DLLEXPORT QoreValue evalMember(const QoreString *member, ExceptionSink *xsink)
returns the value of the member with an incremented reference count, or executes the memberGate() met...
QoreObject::customDeref
virtual DLLLOCAL void customDeref(ExceptionSink *xsink)
custom dereference handler - with delete
QoreObject::tDeref
DLLEXPORT void tDeref()
decrements the existence reference count, when it reaches 0 the C++ object ("this") will be deleted
QoreObject::getAsString
virtual DLLEXPORT int getAsString(QoreString &str, int foff, ExceptionSink *xsink) const
concatenate the verbose string representation of the list (including all contained values) to an exis...
QoreObject::getClassName
DLLEXPORT const char * getClassName() const
returns the name of the class
QoreObject::evalMethod
DLLEXPORT QoreValue evalMethod(const QoreString *name, const QoreListNode *args, ExceptionSink *xsink)
evaluates the given method with the arguments passed and returns the return value,...
QoreObject::isValid
DLLEXPORT bool isValid() const
returns true if the object is valid
QoreObject::isSystemObject
DLLEXPORT bool isSystemObject() const
returns true if the object is a system object (created with the system constructor)
QoreObject::removeMember
DLLEXPORT void removeMember(const QoreString *key, ExceptionSink *xsink)
removes a member from the object without explicitly calling destructors; the value is only dereferenc...
QoreObject::realDeref
DLLEXPORT void realDeref(ExceptionSink *xsink)
decrements the standard reference count of the object for references that cannot be part of a recursi...
QoreObject::copyData
DLLEXPORT QoreHashNode * copyData(ExceptionSink *xsink) const
retuns all member data of the object (or 0 if there's an exception), caller owns the QoreHashNode ref...
QoreObject::compareHard
DLLEXPORT bool compareHard(const QoreObject *obj, ExceptionSink *xsink) const
tests for equality ("deep compare" including all contained values) with possible type conversion of c...
QoreObject::size
DLLEXPORT int size(ExceptionSink *xsink) const
returns the number of members of the object
QoreObject::realCopy
virtual DLLEXPORT AbstractQoreNode * realCopy() const
performs a the same object with its reference count increased
QoreObject::~QoreObject
virtual DLLLOCAL ~QoreObject()
destructor
QoreObject::defaultSystemDestructor
DLLLOCAL void defaultSystemDestructor(qore_classid_t classID, ExceptionSink *xsink)
runs the destructor for system objects
QoreObject::setValue
DLLEXPORT void setValue(const char *key, QoreValue val, ExceptionSink *xsink)
sets the value of the given member to the given value
QoreObject::getStaticTypeCode
static DLLLOCAL qore_type_t getStaticTypeCode()
returns the type code (useful in templates)
Definition: QoreObject.h:168
QoreObject::getProgram
DLLEXPORT QoreProgram * getProgram() const
returns the QoreProgram object associated with this object
QoreObject::addPrivateDataToString
DLLLOCAL void addPrivateDataToString(QoreString *str, ExceptionSink *xsink) const
concatenates info about private data to a string
QoreObject::execMemberNotification
DLLLOCAL void execMemberNotification(const char *member, ExceptionSink *xsink)
executes the member notification on the object the given member
QoreObject::getMemberValueNoMethod
DLLEXPORT QoreValue getMemberValueNoMethod(const QoreString *key, AutoVLock *vl, ExceptionSink *xsink) const
returns the pointer to the value of the member
QoreObject::evalStaticMethodVariant
static DLLEXPORT QoreValue evalStaticMethodVariant(const QoreMethod &method, const QoreExternalMethodVariant *variant, const QoreListNode *args, ExceptionSink *xsink)
executes a static method variant
QoreObject::deleteMemberValue
DLLEXPORT void deleteMemberValue(const QoreString *key, ExceptionSink *xsink)
removes a member from the object, if the member's value is an object it is deleted as well (destructo...
QoreObject::evalMethodVariant
DLLEXPORT QoreValue evalMethodVariant(const QoreMethod &method, const QoreExternalMethodVariant *variant, const QoreListNode *args, ExceptionSink *xsink)
executes a normal object method variant
QoreObject::evalCopyMethodWithPrivateData
DLLLOCAL void evalCopyMethodWithPrivateData(const QoreClass &thisclass, const BuiltinCopyVariantBase *meth, QoreObject *self, ExceptionSink *xsink)
called on the old object (this) to acquire private data, copy method called with pointer to "self" (n...
QoreObject::obliterate
DLLLOCAL void obliterate(ExceptionSink *xsink)
destroys all members and dereferences all private data structures
QoreObject::getAndClearPrivateData
DLLLOCAL AbstractPrivateData * getAndClearPrivateData(qore_classid_t key, ExceptionSink *xsink)
retrieves the private data pointer and clears it from the object's private data store,...
QoreObject::doDelete
DLLEXPORT void doDelete(ExceptionSink *xsink)
runs the destructor on the object (if it hasn't already been deleted)
QoreObject::getReferencedMemberNoMethod
DLLEXPORT QoreValue getReferencedMemberNoMethod(const char *mem, ExceptionSink *xsink) const
returns the value of the given member with the reference count incremented, the caller owns any refer...
QoreObject::deleteBlockerRef
DLLEXPORT void deleteBlockerRef() const
increment the reference count of the object, to be called only from within a delete blocker
QoreObject::validInstanceOf
DLLEXPORT bool validInstanceOf(qore_classid_t cid) const
returns true if this object is a valid instance of the classid passed
QoreObject::externalDelete
DLLEXPORT void externalDelete(qore_classid_t key, ExceptionSink *xsink)
call this function when an object's private data is deleted externally
QoreObject::evalStaticMethod
static DLLEXPORT QoreValue evalStaticMethod(const QoreMethod &method, const QoreListNode *args, ExceptionSink *xsink)
executes a static method
QoreObject::getClassAccess
DLLEXPORT ClassAccess getClassAccess(const QoreClass &cls) const
returns the accessibility of the class in the object's hierachy or Inaccessible the object does not i...
QoreObject::getStaticTypeName
static DLLLOCAL const char * getStaticTypeName()
returns the type name (useful in templates)
Definition: QoreObject.h:163
QoreObject::setPrivate
DLLEXPORT void setPrivate(qore_classid_t key, AbstractPrivateData *pd)
sets private data for the object against the class ID passed, used in C++ functions implementing Qore...
QoreObject::is_equal_hard
virtual DLLEXPORT bool is_equal_hard(const AbstractQoreNode *v, ExceptionSink *xsink) const
tests for equality ("deep compare" including all contained values) without type conversions (hard com...
QoreObject::getMemberAsBigInt
DLLEXPORT int64 getMemberAsBigInt(const char *mem, bool &found, ExceptionSink *xsink) const
returns the value of the given member as an int64
QoreObject::tryGetReferencedPrivateData
DLLEXPORT AbstractPrivateData * tryGetReferencedPrivateData(qore_classid_t key, ExceptionSink *xsink) const
returns the private data corresponding to the class ID passed with an incremented reference count if ...
QoreObject::getClass
DLLEXPORT const QoreClass * getClass() const
returns a pointer to the QoreClass of this object
QoreObject::takeMember
DLLEXPORT QoreValue takeMember(const QoreString *key, ExceptionSink *xsink)
removes a member from the object without explicitly calling destructors and returns the value removed...
QoreObject::getMemberList
DLLEXPORT QoreListNode * getMemberList(ExceptionSink *xsink) const
returns the list of members, caller owns the list returned
QoreObject::realRef
DLLEXPORT void realRef()
increments the standard reference count of the object for references that cannot be part of a recursi...
QoreObject::is_equal_soft
virtual DLLEXPORT bool is_equal_soft(const AbstractQoreNode *v, ExceptionSink *xsink) const
tests for equality ("deep compare" including all contained values) with possible type conversion (sof...
QoreObject::setMemberValue
DLLEXPORT int setMemberValue(const char *key, const QoreClass *cls, const QoreValue val, ExceptionSink *xsink)
sets the value of the given member as accessed from the given class
QoreObject::hasMember
DLLEXPORT bool hasMember(const char *mem, ExceptionSink *xsink) const
returns true if the object has the given member (note that the member may not have a value)
QoreObject::evalImpl
virtual DLLLOCAL QoreValue evalImpl(bool &needs_deref, ExceptionSink *xsink) const
should never be called, does nothing
QoreObject::getAsBoolImpl
virtual DLLEXPORT bool getAsBoolImpl() const
returns false unless perl-boolean-evaluation is enabled, in which case it returns false only when emp...
QoreProgram
supports parsing and executing Qore-language code, reference counted, dynamically-allocated only
Definition: QoreProgram.h:126
QoreString
Qore's string type supported by the QoreEncoding class.
Definition: QoreString.h:81
ReferenceHolder
a templated class to manage a reference count of an object that can throw a Qore-language exception w...
Definition: ReferenceHolder.h:52
TryPrivateDataRefHolder
convenience class for holding AbstractPrivateData references
Definition: QoreObject.h:606
TryPrivateDataRefHolder::operator=
DLLLOCAL void operator=(T *nv)
assigns a new pointer to the holder, dereferences the current pointer if any
Definition: QoreObject.h:612
qore_type_t
int16_t qore_type_t
used to identify unique Qore data and parse types (descendents of AbstractQoreNode)
Definition: common.h:70
qore_classid_t
unsigned qore_classid_t
used for the unique class ID for QoreClass objects
Definition: common.h:79
int64
long long int64
64bit integer type, cannot use int64_t here since it breaks the API on some 64-bit systems due to equ...
Definition: common.h:260
NT_OBJECT
const qore_type_t NT_OBJECT
type value for QoreObject
Definition: node_types.h:52
QoreValue
The main value class in Qore, designed to be passed by value.
Definition: QoreValue.h:262