/*
 * Interface wrapper code.
 *
 * Generated by SIP 6.15.3
 *
 * Copyright (c) 2026 Riverbank Computing Limited <info@riverbankcomputing.com>
 * 
 * This file is part of PyQt6.
 * 
 * This file may be used under the terms of the GNU General Public License
 * version 3.0 as published by the Free Software Foundation and appearing in
 * the file LICENSE included in the packaging of this file.  Please review the
 * following information to ensure the GNU General Public License version 3.0
 * requirements will be met: http://www.gnu.org/copyleft/gpl.html.
 * 
 * If you do not wish to use this file under the terms of the GPL version 3.0
 * then you may purchase a commercial license.  For more information contact
 * info@riverbankcomputing.com.
 * 
 * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
 * WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
 */

#include "sipAPIQtCore.h"

#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qeventloop.sip"
#include <qeventloop.h>
#line 29 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"

#line 28 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qobject.sip"
#include <qobject.h>
#line 33 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 36 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 25 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qflags.sip"
#include <qglobal.h>
#line 39 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qdeadlinetimer.sip"
#include <qdeadlinetimer.h>
#line 42 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 154 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 47 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qmetaobject.sip"
#include <qmetaobject.h>
#line 50 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 277 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 53 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 254 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 56 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 24 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qstring.sip"
#include <qstring.h>
#line 59 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 62 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 28 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 65 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 30 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 68 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 135 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 71 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 154 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qtextstream.sip"
#include <qtextstream.h>
#line 76 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qthread.sip"
#include <qthread.h>
#line 79 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qanystringview.sip"
#include <qanystringview.h>
#line 82 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 25 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qflags.sip"
#include <qglobal.h>
#line 85 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qregularexpression.sip"
#include <qregularexpression.h>
#line 88 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 91 "/build/pyqt6/src/pyqt6-6.11.0/build/QtCore/sipQtCoreQEventLoop.cpp"


class sipQEventLoop : public ::QEventLoop
{
public:
    sipQEventLoop(::QObject*);
    virtual ~sipQEventLoop();

    int qt_metacall(QMetaObject::Call, int, void **) SIP_OVERRIDE;
    void *qt_metacast(const char *) SIP_OVERRIDE;
    const QMetaObject *metaObject() const SIP_OVERRIDE;

    /*
     * There is a protected method for every virtual method visible from
     * this class.
     */
protected:
    bool event(::QEvent*) SIP_OVERRIDE;
    bool eventFilter(::QObject*, ::QEvent*) SIP_OVERRIDE;
    void timerEvent(::QTimerEvent*) SIP_OVERRIDE;
    void childEvent(::QChildEvent*) SIP_OVERRIDE;
    void customEvent(::QEvent*) SIP_OVERRIDE;
    void connectNotify(const ::QMetaMethod&) SIP_OVERRIDE;
    void disconnectNotify(const ::QMetaMethod&) SIP_OVERRIDE;

public:
    sipSimpleWrapper *sipPySelf;

private:
    sipQEventLoop(const sipQEventLoop &);
    sipQEventLoop &operator = (const sipQEventLoop &);

    char sipPyMethods[7];
};

sipQEventLoop::sipQEventLoop(::QObject*a0): ::QEventLoop(a0), sipPySelf(SIP_NULLPTR)
{
    memset(sipPyMethods, 0, sizeof (sipPyMethods));
}

sipQEventLoop::~sipQEventLoop()
{
    sipInstanceDestroyedEx(&sipPySelf);
}

const QMetaObject *sipQEventLoop::metaObject() const
{
    if (sipGetInterpreter())
        return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : sip_QtCore_qt_metaobject(sipPySelf, sipType_QEventLoop);

    return ::QEventLoop::metaObject();
}

int sipQEventLoop::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
{
    _id = ::QEventLoop::qt_metacall(_c, _id, _a);

    if (_id >= 0)
    {
        SIP_BLOCK_THREADS
        _id = sip_QtCore_qt_metacall(sipPySelf, sipType_QEventLoop, _c, _id, _a);
        SIP_UNBLOCK_THREADS
    }

    return _id;
}

void *sipQEventLoop::qt_metacast(const char *_clname)
{
    void *sipCpp;

    return (sip_QtCore_qt_metacast(sipPySelf, sipType_QEventLoop, _clname, &sipCpp) ? sipCpp : ::QEventLoop::qt_metacast(_clname));
}

bool sipQEventLoop::event(::QEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[0], &sipPySelf, SIP_NULLPTR, sipName_event);

    if (!sipMeth)
        return ::QEventLoop::event(a0);

    extern bool sipVH_QtCore_0(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, ::QEvent*);

    return sipVH_QtCore_0(sipGILState, sipVEH_QtCore_PyQt6, sipPySelf, sipMeth, a0);
}

bool sipQEventLoop::eventFilter(::QObject*a0, ::QEvent*a1)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[1], &sipPySelf, SIP_NULLPTR, sipName_eventFilter);

    if (!sipMeth)
        return ::QEventLoop::eventFilter(a0, a1);

    extern bool sipVH_QtCore_1(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, ::QObject*, ::QEvent*);

    return sipVH_QtCore_1(sipGILState, sipVEH_QtCore_PyQt6, sipPySelf, sipMeth, a0, a1);
}

void sipQEventLoop::timerEvent(::QTimerEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[2], &sipPySelf, SIP_NULLPTR, sipName_timerEvent);

    if (!sipMeth)
    {
        ::QEventLoop::timerEvent(a0);
        return;
    }

    extern void sipVH_QtCore_2(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, ::QTimerEvent*);

    sipVH_QtCore_2(sipGILState, sipVEH_QtCore_PyQt6, sipPySelf, sipMeth, a0);
}

void sipQEventLoop::childEvent(::QChildEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[3], &sipPySelf, SIP_NULLPTR, sipName_childEvent);

    if (!sipMeth)
    {
        ::QEventLoop::childEvent(a0);
        return;
    }

    extern void sipVH_QtCore_3(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, ::QChildEvent*);

    sipVH_QtCore_3(sipGILState, sipVEH_QtCore_PyQt6, sipPySelf, sipMeth, a0);
}

void sipQEventLoop::customEvent(::QEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[4], &sipPySelf, SIP_NULLPTR, sipName_customEvent);

    if (!sipMeth)
    {
        ::QEventLoop::customEvent(a0);
        return;
    }

    extern void sipVH_QtCore_4(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, ::QEvent*);

    sipVH_QtCore_4(sipGILState, sipVEH_QtCore_PyQt6, sipPySelf, sipMeth, a0);
}

void sipQEventLoop::connectNotify(const ::QMetaMethod& a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[5], &sipPySelf, SIP_NULLPTR, sipName_connectNotify);

    if (!sipMeth)
    {
        ::QEventLoop::connectNotify(a0);
        return;
    }

    extern void sipVH_QtCore_5(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const ::QMetaMethod&);

    sipVH_QtCore_5(sipGILState, sipVEH_QtCore_PyQt6, sipPySelf, sipMeth, a0);
}

void sipQEventLoop::disconnectNotify(const ::QMetaMethod& a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[6], &sipPySelf, SIP_NULLPTR, sipName_disconnectNotify);

    if (!sipMeth)
    {
        ::QEventLoop::disconnectNotify(a0);
        return;
    }

    extern void sipVH_QtCore_5(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const ::QMetaMethod&);

    sipVH_QtCore_5(sipGILState, sipVEH_QtCore_PyQt6, sipPySelf, sipMeth, a0);
}


PyDoc_STRVAR(doc_QEventLoop_processEvents, "processEvents(self, flags: QEventLoop.ProcessEventsFlag = QEventLoop.AllEvents) -> bool\n"
"processEvents(self, flags: QEventLoop.ProcessEventsFlag, maximumTime: int)\n"
"processEvents(self, flags: QEventLoop.ProcessEventsFlag, deadline: QDeadlineTimer)");

extern "C" {static PyObject *meth_QEventLoop_processEvents(PyObject *, PyObject *, PyObject *);}
static PyObject *meth_QEventLoop_processEvents(PyObject *sipSelf, PyObject *sipArgs, PyObject *sipKwds)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        ::QEventLoop::ProcessEventsFlags a0def = QEventLoop::AllEvents;
        ::QEventLoop::ProcessEventsFlags* a0 = &a0def;
        int a0State = 0;
        ::QEventLoop *sipCpp;

        static const char *sipKwdList[] = {
            sipName_flags,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "B|J1", &sipSelf, sipType_QEventLoop, &sipCpp, sipType_QFlags_0100QEventLoop_ProcessEventsFlag, &a0, &a0State))
        {
            bool sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->processEvents(*a0);
            Py_END_ALLOW_THREADS
            sipReleaseType(a0, sipType_QFlags_0100QEventLoop_ProcessEventsFlag, a0State);

            return PyBool_FromLong(sipRes);
        }
    }

    {
        ::QEventLoop::ProcessEventsFlags* a0;
        int a0State = 0;
        int a1;
        ::QEventLoop *sipCpp;

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, SIP_NULLPTR, "BJ1i", &sipSelf, sipType_QEventLoop, &sipCpp, sipType_QFlags_0100QEventLoop_ProcessEventsFlag, &a0, &a0State, &a1))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->processEvents(*a0, a1);
            Py_END_ALLOW_THREADS
            sipReleaseType(a0, sipType_QFlags_0100QEventLoop_ProcessEventsFlag, a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        ::QEventLoop::ProcessEventsFlags* a0;
        int a0State = 0;
        ::QDeadlineTimer* a1;
        ::QEventLoop *sipCpp;

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, SIP_NULLPTR, "BJ1J9", &sipSelf, sipType_QEventLoop, &sipCpp, sipType_QFlags_0100QEventLoop_ProcessEventsFlag, &a0, &a0State, sipType_QDeadlineTimer, &a1))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->processEvents(*a0, *a1);
            Py_END_ALLOW_THREADS
            sipReleaseType(a0, sipType_QFlags_0100QEventLoop_ProcessEventsFlag, a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QEventLoop, sipName_processEvents, doc_QEventLoop_processEvents);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QEventLoop_exec, "exec(self, flags: QEventLoop.ProcessEventsFlag = QEventLoop.AllEvents) -> int");

extern "C" {static PyObject *meth_QEventLoop_exec(PyObject *, PyObject *, PyObject *);}
static PyObject *meth_QEventLoop_exec(PyObject *sipSelf, PyObject *sipArgs, PyObject *sipKwds)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        ::QEventLoop::ProcessEventsFlags a0def = QEventLoop::AllEvents;
        ::QEventLoop::ProcessEventsFlags* a0 = &a0def;
        int a0State = 0;
        ::QEventLoop *sipCpp;

        static const char *sipKwdList[] = {
            sipName_flags,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "B|J1", &sipSelf, sipType_QEventLoop, &sipCpp, sipType_QFlags_0100QEventLoop_ProcessEventsFlag, &a0, &a0State))
        {
            int sipRes;

            sipCallHook("__pyQtPreEventLoopHook__");

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->exec(*a0);
            Py_END_ALLOW_THREADS
            sipReleaseType(a0, sipType_QFlags_0100QEventLoop_ProcessEventsFlag, a0State);


            sipCallHook("__pyQtPostEventLoopHook__");
            return PyLong_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QEventLoop, sipName_exec, doc_QEventLoop_exec);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QEventLoop_exit, "exit(self, returnCode: int = 0)");

extern "C" {static PyObject *meth_QEventLoop_exit(PyObject *, PyObject *, PyObject *);}
static PyObject *meth_QEventLoop_exit(PyObject *sipSelf, PyObject *sipArgs, PyObject *sipKwds)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        int a0 = 0;
        ::QEventLoop *sipCpp;

        static const char *sipKwdList[] = {
            sipName_returnCode,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "B|i", &sipSelf, sipType_QEventLoop, &sipCpp, &a0))
        {
            sipCpp->exit(a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QEventLoop, sipName_exit, doc_QEventLoop_exit);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QEventLoop_isRunning, "isRunning(self) -> bool");

extern "C" {static PyObject *meth_QEventLoop_isRunning(PyObject *, PyObject *);}
static PyObject *meth_QEventLoop_isRunning(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const ::QEventLoop *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QEventLoop, &sipCpp))
        {
            bool sipRes;

            sipRes = sipCpp->isRunning();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QEventLoop, sipName_isRunning, doc_QEventLoop_isRunning);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QEventLoop_wakeUp, "wakeUp(self)");

extern "C" {static PyObject *meth_QEventLoop_wakeUp(PyObject *, PyObject *);}
static PyObject *meth_QEventLoop_wakeUp(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        ::QEventLoop *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QEventLoop, &sipCpp))
        {
            sipCpp->wakeUp();

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QEventLoop, sipName_wakeUp, doc_QEventLoop_wakeUp);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QEventLoop_quit, "quit(self)");

extern "C" {static PyObject *meth_QEventLoop_quit(PyObject *, PyObject *);}
static PyObject *meth_QEventLoop_quit(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        ::QEventLoop *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QEventLoop, &sipCpp))
        {
            sipCpp->quit();

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QEventLoop, sipName_quit, doc_QEventLoop_quit);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QEventLoop_event, "event(self, event: QEvent|None) -> bool");

extern "C" {static PyObject *meth_QEventLoop_event(PyObject *, PyObject *);}
static PyObject *meth_QEventLoop_event(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_QEventLoop)) || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
        ::QEvent* a0;
        ::QEventLoop *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ8", &sipSelf, sipType_QEventLoop, &sipCpp, sipType_QEvent, &a0))
        {
            bool sipRes;

            sipRes = (sipSelfWasArg ? sipCpp->::QEventLoop::event(a0) : sipCpp->event(a0));

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QEventLoop, sipName_event, doc_QEventLoop_event);

    return SIP_NULLPTR;
}


/* Cast a pointer to a type somewhere in its inheritance hierarchy. */
extern "C" {static void *cast_QEventLoop(void *, const sipTypeDef *);}
static void *cast_QEventLoop(void *sipCppV, const sipTypeDef *targetType)
{
    ::QEventLoop *sipCpp = reinterpret_cast< ::QEventLoop *>(sipCppV);

    if (targetType == sipType_QEventLoop)
        return sipCppV;

    if (targetType == sipType_QObject)
        return static_cast< ::QObject *>(sipCpp);

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_QEventLoop(void *, int);}
static void release_QEventLoop(void *sipCppV, int)
{
    ::QEventLoop *sipCpp = reinterpret_cast< ::QEventLoop *>(sipCppV);

    if (QThread::currentThread() == sipCpp->thread())
        delete sipCpp;
    else
        sipCpp->deleteLater();
}


extern "C" {static void *array_QEventLoop(Py_ssize_t);}
static void *array_QEventLoop(Py_ssize_t sipNrElem)
{
    return new ::QEventLoop[sipNrElem];
}


extern "C" {static void array_delete_QEventLoop(void *);}
static void array_delete_QEventLoop(void *sipCpp)
{
    delete[] reinterpret_cast< ::QEventLoop *>(sipCpp);
}


extern "C" {static void dealloc_QEventLoop(sipSimpleWrapper *);}
static void dealloc_QEventLoop(sipSimpleWrapper *sipSelf)
{
    if (sipIsDerivedClass(sipSelf))
        reinterpret_cast<sipQEventLoop *>(sipGetAddress(sipSelf))->sipPySelf = SIP_NULLPTR;

    if (sipIsOwnedByPython(sipSelf))
    {
        release_QEventLoop(sipGetAddress(sipSelf), sipIsDerivedClass(sipSelf));
    }
}


extern "C" {static void *init_type_QEventLoop(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_QEventLoop(sipSimpleWrapper *sipSelf, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **sipOwner, PyObject **sipParseErr)
{
    sipQEventLoop *sipCpp = SIP_NULLPTR;

    {
        ::QObject* a0 = 0;

        static const char *sipKwdList[] = {
            sipName_parent,
        };

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, sipKwdList, sipUnused, "|JH", sipType_QObject, &a0, sipOwner))
        {
            sipCpp = new sipQEventLoop(a0);

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's super-types. */
static sipEncodedTypeDef supers_QEventLoop[] = {{255, 255, 1}};


static PyMethodDef methods_QEventLoop[] = {
    {sipName_event, meth_QEventLoop_event, METH_VARARGS, doc_QEventLoop_event},
    {sipName_exec, SIP_MLMETH_CAST(meth_QEventLoop_exec), METH_VARARGS|METH_KEYWORDS, doc_QEventLoop_exec},
    {sipName_exit, SIP_MLMETH_CAST(meth_QEventLoop_exit), METH_VARARGS|METH_KEYWORDS, doc_QEventLoop_exit},
    {sipName_isRunning, meth_QEventLoop_isRunning, METH_VARARGS, doc_QEventLoop_isRunning},
    {sipName_processEvents, SIP_MLMETH_CAST(meth_QEventLoop_processEvents), METH_VARARGS|METH_KEYWORDS, doc_QEventLoop_processEvents},
    {sipName_quit, meth_QEventLoop_quit, METH_VARARGS, doc_QEventLoop_quit},
    {sipName_wakeUp, meth_QEventLoop_wakeUp, METH_VARARGS, doc_QEventLoop_wakeUp}
};


/* Define the enum members and ints to be added to this type. */
static sipIntInstanceDef intInstances_QEventLoop[] = {
    {sipName_AllEvents, static_cast<int>(::QEventLoop::AllEvents)},
    {sipName_ExcludeUserInputEvents, static_cast<int>(::QEventLoop::ExcludeUserInputEvents)},
    {sipName_ExcludeSocketNotifiers, static_cast<int>(::QEventLoop::ExcludeSocketNotifiers)},
    {sipName_WaitForMoreEvents, static_cast<int>(::QEventLoop::WaitForMoreEvents)},
    {0, 0}
};

PyDoc_STRVAR(doc_QEventLoop, "\1QEventLoop(parent: QObject|None = None)");


static pyqt6ClassPluginDef plugin_QEventLoop = {
    &::QEventLoop::staticMetaObject,
    SIP_NULLPTR,
    SIP_NULLPTR
};


sipClassTypeDef sipTypeDef_QtCore_QEventLoop = {
    {
        SIP_NULLPTR,
        SIP_TYPE_SCC|SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QEventLoop,
        SIP_NULLPTR,
        &plugin_QEventLoop,
    },
    {
        sipNameNr_QEventLoop,
        {0, 0, 1},
        7, methods_QEventLoop,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, intInstances_QEventLoop, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QEventLoop,
    -1,
    -1,
    supers_QEventLoop,
    SIP_NULLPTR,
    init_type_QEventLoop,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QEventLoop,
    SIP_NULLPTR,
    array_QEventLoop,
    SIP_NULLPTR,
    release_QEventLoop,
    cast_QEventLoop,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    array_delete_QEventLoop,
    sizeof (::QEventLoop),
};
