3#ifndef QV4PROMISEOBJECT_H
4#define QV4PROMISEOBJECT_H
24struct PromiseCapability;
29struct ResolveThenableEvent;
56#define PromiseObjectMembers(class, Member) \
57 Member(class, HeapValue, HeapValue, resolution) \
58 Member(class, HeapValue, HeapValue, fulfillReactions) \
59 Member(class, HeapValue, HeapValue, rejectReactions)
72 bool isSettled()
const;
73 bool isPending()
const;
74 bool isFulfilled()
const;
75 bool isRejected()
const;
83#define PromiseCapabilityMembers(class, Member) \
84 Member(class, HeapValue, HeapValue, promise) \
85 Member(class, HeapValue, HeapValue, resolve) \
86 Member(class, HeapValue, HeapValue, reject)
92#define PromiseReactionMembers(class, Member) \
93 Member(class, HeapValue, HeapValue, handler) \
94 Member(class, Pointer, PromiseCapability*, capability)
112 friend class ReactionHandler;
115#define CapabilitiesExecutorWrapperMembers(class, Member) \
116 Member(class, Pointer, PromiseCapability*, capabilities)
124#define PromiseExecutionStateMembers(class, Member) \
125 Member(class, HeapValue, HeapValue, values) \
126 Member(class, HeapValue, HeapValue, capability)
133 uint remainingElementCount;
136#define ResolveElementWrapperMembers(class, Member) \
137 Member(class, HeapValue, HeapValue, state)
144 bool alreadyResolved;
147#define ResolveWrapperMembers(class, Member) \
148 Member(class, Pointer, PromiseObject*, promise)
154 bool alreadyResolved;
157#define RejectWrapperMembers(class, Member) \
158 Member(class, Pointer, PromiseObject*, promise)
164 bool alreadyResolved;
QObject * parent() const
Returns a pointer to the parent object.
void addResolveThenable(ExecutionEngine *e, const PromiseObject *promise, const Object *thenable, const FunctionObject *then)
void customEvent(QEvent *event) override
This event handler can be reimplemented in a subclass to receive custom events.
~ReactionHandler() override
void addReaction(ExecutionEngine *e, const Value *reaction, const Value *value)
void executeResolveThenable(ResolveThenableEvent *event)
void executeReaction(ReactionEvent *event)
Combined button and popup list for selecting options.
\qmltype Particle \inqmlmodule QtQuick.Particles
EGLOutputLayerEXT EGLint EGLAttrib value
[5]
static QT_BEGIN_NAMESPACE void init(QTextBoundaryFinder::BoundaryType type, QStringView str, QCharAttributes *attributes)
#define DECLARE_HEAP_OBJECT(name, base)
#define DECLARE_MARKOBJECTS(class)
#define V4_OBJECT2(DataClass, superClass)
Heap::ExecutionContext * scope() const
void init(QV4::ExecutionContext *scope)
ExecutionEngine * engine() const
static ReturnedValue method_all(const FunctionObject *f, const Value *thisObject, const Value *argv, int argc)
static ReturnedValue method_race(const FunctionObject *f, const Value *thisObject, const Value *argv, int argc)
static ReturnedValue method_reject(const FunctionObject *f, const Value *thisObject, const Value *argv, int argc)
static ReturnedValue method_resolve(const FunctionObject *f, const Value *thisObject, const Value *argv, int argc)
static ReturnedValue method_catch(const FunctionObject *f, const Value *thisObject, const Value *argv, int argc)
static ReturnedValue method_then(const FunctionObject *f, const Value *thisObject, const Value *argv, int argc)
void init(ExecutionEngine *engine, Object *ctor)
static constexpr VTable::CallAsConstructor virtualCallAsConstructor
static constexpr VTable::Call virtualCall