
// Workaround to access protected functions
#ifndef protected
#  define protected public
#endif

// default includes
#include <shiboken.h>
#include <sbkpep.h>
#include <sbkpepbuffer.h>

#define PYSIDE6_COMOPT_COMPRESS 1

#ifndef QT_NO_VERSION_TAGGING
#  define QT_NO_VERSION_TAGGING
#endif
#include <QtCore/QDebug>
#include <pysideqobject.h>
#include <pysidesignal.h>
#include <pysideproperty.h>
#include <signalmanager.h>
#include <pysidemetafunction.h>
#include <pysideqenum.h>
#include <pysideutils.h>
#include <feature_select.h>
QT_WARNING_DISABLE_DEPRECATED


// module include
#include "kcalendarcore_python.h"

// main header
#include "kcalendarcore_memorycalendar_wrapper.h"

// Wrappers providing overrides
#include "kcalendarcore_calendarlistmodel_wrapper.h"
#include "kcalendarcore_customproperties_wrapper.h"
#include "kcalendarcore_incidencebase_incidenceobserver_wrapper.h"

// Argument includes
#include <QString>
#include <qbytearray.h>
#include <qdatetime.h>
#include <qobject.h>
#include <qobjectdefs.h>
#include <qtimezone.h>

#include <algorithm>
#include <cctype>
#include <cstring>
#include <iterator>
#include <set>
#include <type_traits>
#include <typeinfo>

using namespace KCalendarCore;

extern "C" {
static PyTypeObject *Sbk_KCalendarCore_MemoryCalendar_TypeF(void)
{
    return SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX].type;
}
} // extern "C"

// Native ---------------------------------------------------------

void MemoryCalendarWrapper::resetPyMethodCache()
{
    std::fill(m_PyMethodCache.begin(), m_PyMethodCache.end(), nullptr);
}

MemoryCalendarWrapper::MemoryCalendarWrapper(const ::QByteArray & timeZoneId) : KCalendarCore::MemoryCalendar(timeZoneId)
{
}

MemoryCalendarWrapper::MemoryCalendarWrapper(const ::QTimeZone & timeZone) : KCalendarCore::MemoryCalendar(timeZone)
{
}

void MemoryCalendarWrapper::childEvent(::QChildEvent * event)
{
    static const char *funcName = "childEvent";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[0], nameCache));
    if (pyOverride.isNull()) {
        return this->::QObject::childEvent(event);
    }
    CalendarListModelWrapper::sbk_o_childEvent("MemoryCalendar", funcName, gil, pyOverride, event);
}

void MemoryCalendarWrapper::connectNotify(const ::QMetaMethod & signal)
{
    static const char *funcName = "connectNotify";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[1], nameCache));
    if (pyOverride.isNull()) {
        return this->::QObject::connectNotify(signal);
    }
    CalendarListModelWrapper::sbk_o_connectNotify("MemoryCalendar", funcName, gil, pyOverride, signal);
}

void MemoryCalendarWrapper::customEvent(::QEvent * event)
{
    static const char *funcName = "customEvent";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[2], nameCache));
    if (pyOverride.isNull()) {
        return this->::QObject::customEvent(event);
    }
    CalendarListModelWrapper::sbk_o_customEvent("MemoryCalendar", funcName, gil, pyOverride, event);
}

void MemoryCalendarWrapper::customPropertyUpdate()
{
    static const char *funcName = "customPropertyUpdate";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[3], nameCache));
    if (pyOverride.isNull()) {
        return this->::KCalendarCore::CustomProperties::customPropertyUpdate();
    }
    CustomPropertiesWrapper::sbk_o_customPropertyUpdate("MemoryCalendar", funcName, gil, pyOverride);
}

void MemoryCalendarWrapper::customPropertyUpdated()
{
    static const char *funcName = "customPropertyUpdated";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[4], nameCache));
    if (pyOverride.isNull()) {
        return this->::KCalendarCore::Calendar::customPropertyUpdated();
    }
    CustomPropertiesWrapper::sbk_o_customPropertyUpdate("MemoryCalendar", funcName, gil, pyOverride);
}

void MemoryCalendarWrapper::disconnectNotify(const ::QMetaMethod & signal)
{
    static const char *funcName = "disconnectNotify";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[5], nameCache));
    if (pyOverride.isNull()) {
        return this->::QObject::disconnectNotify(signal);
    }
    CalendarListModelWrapper::sbk_o_connectNotify("MemoryCalendar", funcName, gil, pyOverride, signal);
}

void MemoryCalendarWrapper::doSetTimeZone(const ::QTimeZone & timeZone)
{
    static const char *funcName = "doSetTimeZone";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[6], nameCache));
    if (pyOverride.isNull()) {
        return this->::KCalendarCore::MemoryCalendar::doSetTimeZone(timeZone);
    }
    sbk_o_doSetTimeZone("MemoryCalendar", funcName, gil, pyOverride, timeZone);
}

void MemoryCalendarWrapper::sbk_o_doSetTimeZone([[maybe_unused]] const char *ownerClassName, [[maybe_unused]] const char *funcName, [[maybe_unused]] Shiboken::GilState &gil, [[maybe_unused]] const Shiboken::AutoDecRef &pyOverride, [[maybe_unused]] const ::QTimeZone & timeZone)
{
#if !defined(PYPY_VERSION) && (!defined(Py_LIMITED_API) || Py_LIMITED_API >= 0x030C0000)
    PyObject *pyArgArray[1] = {
        Shiboken::Conversions::copyToPython(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QTimeZone_IDX]), &timeZone)
    };
#else
    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::copyToPython(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QTimeZone_IDX]), &timeZone)
    ));
#endif

#if !defined(PYPY_VERSION) && (!defined(Py_LIMITED_API) || Py_LIMITED_API >= 0x030C0000)
    Shiboken::AutoDecRef pyResult(PyObject_Vectorcall(pyOverride, pyArgArray, 1, nullptr));
    Py_DECREF(pyArgArray[0]);
#else
    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
#endif
    if (pyResult.isNull()) {
        // An error happened in python code!
        Shiboken::Errors::storePythonOverrideErrorOrPrint(ownerClassName, funcName);
        return;
    }
}

void MemoryCalendarWrapper::endBatchAdding()
{
    static const char *funcName = "endBatchAdding";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[7], nameCache));
    if (pyOverride.isNull()) {
        return this->::KCalendarCore::Calendar::endBatchAdding();
    }
    CustomPropertiesWrapper::sbk_o_customPropertyUpdate("MemoryCalendar", funcName, gil, pyOverride);
}

bool MemoryCalendarWrapper::event(::QEvent * event)
{
    static const char *funcName = "event";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[8], nameCache));
    if (pyOverride.isNull()) {
        return this->::QObject::event(event);
    }
    return CalendarListModelWrapper::sbk_o_event("MemoryCalendar", funcName, gil, pyOverride, event);
}

bool MemoryCalendarWrapper::eventFilter(::QObject * watched, ::QEvent * event)
{
    static const char *funcName = "eventFilter";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[9], nameCache));
    if (pyOverride.isNull()) {
        return this->::QObject::eventFilter(watched, event);
    }
    return CalendarListModelWrapper::sbk_o_eventFilter("MemoryCalendar", funcName, gil, pyOverride, watched, event);
}

void MemoryCalendarWrapper::incidenceUpdate(const ::QString & uid, const ::QDateTime & recurrenceId)
{
    static const char *funcName = "incidenceUpdate";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[10], nameCache));
    if (pyOverride.isNull()) {
        return this->::KCalendarCore::MemoryCalendar::incidenceUpdate(uid, recurrenceId);
    }
    IncidenceObserverWrapper::sbk_o_incidenceUpdate("MemoryCalendar", funcName, gil, pyOverride, uid, recurrenceId);
}

void MemoryCalendarWrapper::incidenceUpdated(const ::QString & uid, const ::QDateTime & recurrenceId)
{
    static const char *funcName = "incidenceUpdated";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[11], nameCache));
    if (pyOverride.isNull()) {
        return this->::KCalendarCore::MemoryCalendar::incidenceUpdated(uid, recurrenceId);
    }
    IncidenceObserverWrapper::sbk_o_incidenceUpdate("MemoryCalendar", funcName, gil, pyOverride, uid, recurrenceId);
}

void MemoryCalendarWrapper::startBatchAdding()
{
    static const char *funcName = "startBatchAdding";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[12], nameCache));
    if (pyOverride.isNull()) {
        return this->::KCalendarCore::Calendar::startBatchAdding();
    }
    CustomPropertiesWrapper::sbk_o_customPropertyUpdate("MemoryCalendar", funcName, gil, pyOverride);
}

void MemoryCalendarWrapper::timerEvent(::QTimerEvent * event)
{
    static const char *funcName = "timerEvent";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[13], nameCache));
    if (pyOverride.isNull()) {
        return this->::QObject::timerEvent(event);
    }
    CalendarListModelWrapper::sbk_o_timerEvent("MemoryCalendar", funcName, gil, pyOverride, event);
}

void MemoryCalendarWrapper::virtual_hook(int id, void * data)
{
    static const char *funcName = "virtual_hook";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_KCalendarCore_MemoryCalendar_TypeF(), gil, funcName, m_PyMethodCache[14], nameCache));
    if (pyOverride.isNull()) {
        return this->::KCalendarCore::MemoryCalendar::virtual_hook(id, data);
    }
    sbk_o_virtual_hook("MemoryCalendar", funcName, gil, pyOverride, id, data);
}

void MemoryCalendarWrapper::sbk_o_virtual_hook([[maybe_unused]] const char *ownerClassName, [[maybe_unused]] const char *funcName, [[maybe_unused]] Shiboken::GilState &gil, [[maybe_unused]] const Shiboken::AutoDecRef &pyOverride, [[maybe_unused]] int id, [[maybe_unused]] void * data)
{
#if !defined(PYPY_VERSION) && (!defined(Py_LIMITED_API) || Py_LIMITED_API >= 0x030C0000)
    PyObject *pyArgArray[2] = {
        Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<int>(), &id),
        Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<void *>(), data)
    };
#else
    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(iN)",
        id,
        Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<void *>(), data)
    ));
#endif

#if !defined(PYPY_VERSION) && (!defined(Py_LIMITED_API) || Py_LIMITED_API >= 0x030C0000)
    Shiboken::AutoDecRef pyResult(PyObject_Vectorcall(pyOverride, pyArgArray, 2, nullptr));
    Py_DECREF(pyArgArray[0]);
    Py_DECREF(pyArgArray[1]);
#else
    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
#endif
    if (pyResult.isNull()) {
        // An error happened in python code!
        Shiboken::Errors::storePythonOverrideErrorOrPrint(ownerClassName, funcName);
        return;
    }
}

const QMetaObject *MemoryCalendarWrapper::metaObject() const
{
    if (QObject::d_ptr->metaObject != nullptr)
        return QObject::d_ptr->dynamicMetaObject();
    SbkObject *pySelf = Shiboken::BindingManager::instance().retrieveWrapper(this);
    if (pySelf == nullptr)
        return KCalendarCore::MemoryCalendar::metaObject();
    return PySide::SignalManager::retrieveMetaObject(reinterpret_cast<PyObject *>(pySelf));
}

int MemoryCalendarWrapper::qt_metacall(QMetaObject::Call call, int id, void **args)
{
    int result = KCalendarCore::MemoryCalendar::qt_metacall(call, id, args);
    return result < 0 ? result : PySide::SignalManager::qt_metacall(this, call, id, args);
}

void *MemoryCalendarWrapper::qt_metacast(const char *_clname)
{
    if (_clname == nullptr)
        return {};
    if (SbkObject *pySelf = Shiboken::BindingManager::instance().retrieveWrapper(this)) {
        auto *obSelf = reinterpret_cast<PyObject *>(pySelf);
        if (PySide::inherits(Py_TYPE(obSelf), _clname))
            return static_cast<void *>(const_cast< MemoryCalendarWrapper *>(this));
    }
    return KCalendarCore::MemoryCalendar::qt_metacast(_clname);
}

MemoryCalendarWrapper::~MemoryCalendarWrapper()
{
    auto *wrapper = Shiboken::BindingManager::instance().retrieveWrapper(this, Sbk_KCalendarCore_MemoryCalendar_TypeF());
    Shiboken::Object::destroy(wrapper, this);
}

// Target ---------------------------------------------------------

extern "C" {
static int
Sbk_KCalendarCore_MemoryCalendar_Init(PyObject *self, PyObject *args, [[maybe_unused]] PyObject *kwds)
{
    auto *sbkSelf = reinterpret_cast<SbkObject *>(self);
    PySide::Feature::Select(self);
    if (Shiboken::Object::isUserType(self) && !Shiboken::ObjectType::canCallConstructor(self->ob_type, Shiboken::SbkType< ::KCalendarCore::MemoryCalendar >()))
        return -1;

    MemoryCalendarWrapper *cptr{};
    Shiboken::AutoDecRef errInfo{};
    Shiboken::PythonContextMarker pcm;
    int overloadId = -1;
    [[maybe_unused]] Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    const Py_ssize_t numArgs = PyTuple_Size(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {nullptr};

    // invalid argument lengths

    if (PyArg_UnpackTuple(args, "MemoryCalendar", 1, 1, &(pyArgs[0])) == 0)
        return -1;


    // Overloaded function decisor
    // 0: MemoryCalendar::MemoryCalendar(const QByteArray&)
    // 1: MemoryCalendar::MemoryCalendar(const QTimeZone&)
    if (numArgs == 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppReferenceConversion(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QTimeZone_IDX]), (pyArgs[0])))) {
        overloadId = 1; // MemoryCalendar::MemoryCalendar(const QTimeZone&)
    } else if (numArgs == 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppReferenceConversion(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QByteArray_IDX]), (pyArgs[0])))) {
        overloadId = 0; // MemoryCalendar::MemoryCalendar(const QByteArray&)
    }

    // Function signature not found.
    if (overloadId == -1)
        return Shiboken::returnWrongArguments_MinusOne(args, "__init__", SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]);


    // PyMI support
    [[maybe_unused]] const bool usesPyMI = Shiboken::callInheritedInit(self, args, kwds, SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]);
    if (Shiboken::Errors::occurred() != nullptr)
        return -1;

    // Call function/method
    switch (overloadId) {
        case 0: // MemoryCalendar(const QByteArray &timeZoneId)
        {
            if (!Shiboken::Object::isValid(pyArgs[0]))
                return -1;
            ::QByteArray cppArg0_local;
            ::QByteArray *cppArg0 = &cppArg0_local;
            if (pythonToCpp[0].isValue())
                pythonToCpp[0](pyArgs[0], &cppArg0_local);
            else
                pythonToCpp[0](pyArgs[0], &cppArg0);


            if (Shiboken::Errors::occurred() == nullptr) {
                // MemoryCalendar::MemoryCalendar(const QByteArray&)
                void *addr = PySide::nextQObjectMemoryAddr();
                if (addr != nullptr) {
                    cptr = new (addr) MemoryCalendarWrapper(*cppArg0);
                    PySide::setNextQObjectMemoryAddr(nullptr);
                } else {
                    cptr = new MemoryCalendarWrapper(*cppArg0);
                }

            }
            break;
        }
        case 1: // MemoryCalendar(const QTimeZone &timeZone)
        {
            if (!Shiboken::Object::isValid(pyArgs[0]))
                return -1;
            ::QTimeZone cppArg0_local;
            ::QTimeZone *cppArg0 = &cppArg0_local;
            if (pythonToCpp[0].isValue())
                pythonToCpp[0](pyArgs[0], &cppArg0_local);
            else
                pythonToCpp[0](pyArgs[0], &cppArg0);


            if (Shiboken::Errors::occurred() == nullptr) {
                // MemoryCalendar::MemoryCalendar(const QTimeZone&)
                void *addr = PySide::nextQObjectMemoryAddr();
                if (addr != nullptr) {
                    cptr = new (addr) MemoryCalendarWrapper(*cppArg0);
                    PySide::setNextQObjectMemoryAddr(nullptr);
                } else {
                    cptr = new MemoryCalendarWrapper(*cppArg0);
                }

            }
            break;
        }
    }

    if (Shiboken::Errors::occurred() != nullptr || !Shiboken::Object::setCppPointer(sbkSelf, Shiboken::SbkType< KCalendarCore::MemoryCalendar >(), cptr)) {
        delete cptr;
        return -1;
    }
    if (cptr == nullptr)
        return Shiboken::returnWrongArguments_MinusOne(args, "__init__", SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]);

    Shiboken::Object::setValidCpp(sbkSelf, true);
    Shiboken::Object::setHasCppWrapper(sbkSelf, true);
    Shiboken::BindingManager::instance().registerWrapper(sbkSelf, cptr);

    // QObject setup
    PySide::Signal::updateSourceObject(self);


    return 1;
}

static PyObject *Sbk_KCalendarCore_MemoryCalendarFunc_doSetTimeZone(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::KCalendarCore::MemoryCalendar *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]), reinterpret_cast<SbkObject *>(self)));
    Shiboken::AutoDecRef errInfo{};
    Shiboken::PythonContextMarker pcm;
    int overloadId = -1;
    [[maybe_unused]] Shiboken::Conversions::PythonToCppConversion pythonToCpp;

    // Overloaded function decisor
    // 0: Calendar::doSetTimeZone(const QTimeZone&)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QTimeZone_IDX]), (pyArg)))) {
        overloadId = 0; // Calendar::doSetTimeZone(const QTimeZone&)
    }

    // Function signature not found.
    if (overloadId == -1)
        return Shiboken::returnWrongArguments(pyArg, "doSetTimeZone", SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]);

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QTimeZone cppArg0_local;
        ::QTimeZone *cppArg0 = &cppArg0_local;
        if (pythonToCpp.isValue())
            pythonToCpp(pyArg, &cppArg0_local);
        else
            pythonToCpp(pyArg, &cppArg0);


        if (Shiboken::Errors::occurred() == nullptr) {
            // Calendar::doSetTimeZone(const QTimeZone&)
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::KCalendarCore::MemoryCalendar::doSetTimeZone(*cppArg0)
                : cppSelf->doSetTimeZone(*cppArg0);
        }
    }

     return Sbk_ReturnFromPython_None();
}

static PyObject *Sbk_KCalendarCore_MemoryCalendarFunc_incidenceUpdate(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::KCalendarCore::MemoryCalendar *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]), reinterpret_cast<SbkObject *>(self)));
    Shiboken::AutoDecRef errInfo{};
    Shiboken::PythonContextMarker pcm;
    int overloadId = -1;
    [[maybe_unused]] Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    const Py_ssize_t numArgs = PyTuple_Size(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {nullptr, nullptr};

    // invalid argument lengths

    if (PyArg_UnpackTuple(args, "incidenceUpdate", 2, 2, &(pyArgs[0]), &(pyArgs[1])) == 0)
        return {};


    // Overloaded function decisor
    // 0: IncidenceObserver::incidenceUpdate(const QString&,const QDateTime&)
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QString_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppReferenceConversion(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QDateTime_IDX]), (pyArgs[1])))) {
        overloadId = 0; // IncidenceObserver::incidenceUpdate(const QString&,const QDateTime&)
    }

    // Function signature not found.
    if (overloadId == -1)
        return Shiboken::returnWrongArguments(args, "incidenceUpdate", SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]);

    // Call function/method
    {
        ::QString cppArg0;
        pythonToCpp[0](pyArgs[0], &cppArg0);
        if (!Shiboken::Object::isValid(pyArgs[1]))
            return {};
        ::QDateTime cppArg1_local;
        ::QDateTime *cppArg1 = &cppArg1_local;
        if (pythonToCpp[1].isValue())
            pythonToCpp[1](pyArgs[1], &cppArg1_local);
        else
            pythonToCpp[1](pyArgs[1], &cppArg1);


        if (Shiboken::Errors::occurred() == nullptr) {
            // IncidenceObserver::incidenceUpdate(const QString&,const QDateTime&)
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::KCalendarCore::MemoryCalendar::incidenceUpdate(cppArg0, *cppArg1)
                : cppSelf->incidenceUpdate(cppArg0, *cppArg1);
        }
    }

     return Sbk_ReturnFromPython_None();
}

static PyObject *Sbk_KCalendarCore_MemoryCalendarFunc_incidenceUpdated(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::KCalendarCore::MemoryCalendar *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]), reinterpret_cast<SbkObject *>(self)));
    Shiboken::AutoDecRef errInfo{};
    Shiboken::PythonContextMarker pcm;
    int overloadId = -1;
    [[maybe_unused]] Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    const Py_ssize_t numArgs = PyTuple_Size(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {nullptr, nullptr};

    // invalid argument lengths

    if (PyArg_UnpackTuple(args, "incidenceUpdated", 2, 2, &(pyArgs[0]), &(pyArgs[1])) == 0)
        return {};


    // Overloaded function decisor
    // 0: IncidenceObserver::incidenceUpdated(const QString&,const QDateTime&)
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QString_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppReferenceConversion(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QDateTime_IDX]), (pyArgs[1])))) {
        overloadId = 0; // IncidenceObserver::incidenceUpdated(const QString&,const QDateTime&)
    }

    // Function signature not found.
    if (overloadId == -1)
        return Shiboken::returnWrongArguments(args, "incidenceUpdated", SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]);

    // Call function/method
    {
        ::QString cppArg0;
        pythonToCpp[0](pyArgs[0], &cppArg0);
        if (!Shiboken::Object::isValid(pyArgs[1]))
            return {};
        ::QDateTime cppArg1_local;
        ::QDateTime *cppArg1 = &cppArg1_local;
        if (pythonToCpp[1].isValue())
            pythonToCpp[1](pyArgs[1], &cppArg1_local);
        else
            pythonToCpp[1](pyArgs[1], &cppArg1);


        if (Shiboken::Errors::occurred() == nullptr) {
            // IncidenceObserver::incidenceUpdated(const QString&,const QDateTime&)
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::KCalendarCore::MemoryCalendar::incidenceUpdated(cppArg0, *cppArg1)
                : cppSelf->incidenceUpdated(cppArg0, *cppArg1);
        }
    }

     return Sbk_ReturnFromPython_None();
}

static PyObject *Sbk_KCalendarCore_MemoryCalendarFunc_setUpdateLastModifiedOnChange(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::KCalendarCore::MemoryCalendar *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]), reinterpret_cast<SbkObject *>(self)));
    Shiboken::AutoDecRef errInfo{};
    Shiboken::PythonContextMarker pcm;
    int overloadId = -1;
    [[maybe_unused]] Shiboken::Conversions::PythonToCppConversion pythonToCpp;

    // Overloaded function decisor
    // 0: MemoryCalendar::setUpdateLastModifiedOnChange(bool)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), (pyArg)))) {
        overloadId = 0; // MemoryCalendar::setUpdateLastModifiedOnChange(bool)
    }

    // Function signature not found.
    if (overloadId == -1)
        return Shiboken::returnWrongArguments(pyArg, "setUpdateLastModifiedOnChange", SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]);

    // Call function/method
    {
        bool cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (Shiboken::Errors::occurred() == nullptr) {
            // MemoryCalendar::setUpdateLastModifiedOnChange(bool)
            cppSelf->setUpdateLastModifiedOnChange(cppArg0);
        }
    }

     return Sbk_ReturnFromPython_None();
}

static PyObject *Sbk_KCalendarCore_MemoryCalendarFunc_updateLastModifiedOnChange(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::KCalendarCore::MemoryCalendar *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]), reinterpret_cast<SbkObject *>(self)));
    PyObject *pyResult{};
    Shiboken::PythonContextMarker pcm;

    // Call function/method
    {

        // MemoryCalendar::updateLastModifiedOnChange()const->bool
        bool cppResult = const_cast<const ::KCalendarCore::MemoryCalendar *>(cppSelf)->updateLastModifiedOnChange();
        pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

static PyObject *Sbk_KCalendarCore_MemoryCalendarFunc_virtual_hook(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::KCalendarCore::MemoryCalendar *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]), reinterpret_cast<SbkObject *>(self)));
    Shiboken::AutoDecRef errInfo{};
    Shiboken::PythonContextMarker pcm;
    int overloadId = -1;
    [[maybe_unused]] Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    const Py_ssize_t numArgs = PyTuple_Size(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {nullptr, nullptr};

    // invalid argument lengths

    if (PyArg_UnpackTuple(args, "virtual_hook", 2, 2, &(pyArgs[0]), &(pyArgs[1])) == 0)
        return {};


    // Overloaded function decisor
    // 0: Calendar::virtual_hook(int,void*)
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<void *>(), (pyArgs[1])))) {
        overloadId = 0; // Calendar::virtual_hook(int,void*)
    }

    // Function signature not found.
    if (overloadId == -1)
        return Shiboken::returnWrongArguments(args, "virtual_hook", SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]);

    // Call function/method
    {
        int cppArg0;
        pythonToCpp[0](pyArgs[0], &cppArg0);
        void* cppArg1;
        pythonToCpp[1](pyArgs[1], &cppArg1);

        if (Shiboken::Errors::occurred() == nullptr) {
            // Calendar::virtual_hook(int,void*)
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::KCalendarCore::MemoryCalendar::virtual_hook(cppArg0, cppArg1)
                : cppSelf->virtual_hook(cppArg0, cppArg1);
        }
    }

     return Sbk_ReturnFromPython_None();
}


static const char *Sbk_KCalendarCore_MemoryCalendar_PropertyStrings[] = {
    nullptr // Sentinel
};

static PyMethodDef Sbk_KCalendarCore_MemoryCalendar_methods[] = {
    {"doSetTimeZone", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_MemoryCalendarFunc_doSetTimeZone), METH_O, nullptr},
    {"incidenceUpdate", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_MemoryCalendarFunc_incidenceUpdate), METH_VARARGS, nullptr},
    {"incidenceUpdated", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_MemoryCalendarFunc_incidenceUpdated), METH_VARARGS, nullptr},
    {"setUpdateLastModifiedOnChange", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_MemoryCalendarFunc_setUpdateLastModifiedOnChange), METH_O, nullptr},
    {"updateLastModifiedOnChange", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_MemoryCalendarFunc_updateLastModifiedOnChange), METH_NOARGS, nullptr},
    {"virtual_hook", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_MemoryCalendarFunc_virtual_hook), METH_VARARGS, nullptr},
    {nullptr, nullptr, 0, nullptr} // Sentinel
};

static int Sbk_KCalendarCore_MemoryCalendar_setattro(PyObject *self, PyObject *name, PyObject *value)
{
    PySide::Feature::Select(self);
    if (value != nullptr && PyCallable_Check(value) != 0) {
        auto plain_inst = reinterpret_cast< ::KCalendarCore::MemoryCalendar *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX]), reinterpret_cast<SbkObject *>(self)));
        auto *inst = dynamic_cast<MemoryCalendarWrapper *>(plain_inst);
        if (inst != nullptr)
            inst->resetPyMethodCache();
    }
    Shiboken::AutoDecRef pp(reinterpret_cast<PyObject *>(PySide::Property::getObject(self, name)));
    if (!pp.isNull())
        return PySide::Property::setValue(reinterpret_cast<PySideProperty *>(pp.object()), self, value);
    return PyObject_GenericSetAttr(self, name, value);
}

} // extern "C"

static int Sbk_KCalendarCore_MemoryCalendar_traverse(PyObject *self, visitproc visit, void *arg)
{
    auto traverseProc = reinterpret_cast<traverseproc>(PyType_GetSlot(SbkObject_TypeF(), Py_tp_traverse));
    ;
    return traverseProc(self, visit, arg);
}
static int Sbk_KCalendarCore_MemoryCalendar_clear(PyObject *self)
{
    auto clearProc = reinterpret_cast<inquiry>(PyType_GetSlot(SbkObject_TypeF(), Py_tp_clear));
    ;
    return clearProc(self);
}
static void * Sbk_KCalendarCore_MemoryCalendarSpecialCastFunction(void *obj, PyTypeObject *desiredType)
{
    auto me = reinterpret_cast< ::KCalendarCore::MemoryCalendar *>(obj);
    if (desiredType == Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_Calendar_IDX]))
        return static_cast< ::KCalendarCore::Calendar *>(me);
    else if (desiredType == Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QObject_IDX]))
        return static_cast< ::QObject *>(me);
    else if (desiredType == Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_CustomProperties_IDX]))
        return static_cast< ::KCalendarCore::CustomProperties *>(me);
    else if (desiredType == Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_IncidenceBase_IncidenceObserver_IDX]))
        return static_cast< ::KCalendarCore::IncidenceBase::IncidenceObserver *>(me);
    return me;
}



// Class Definition -----------------------------------------------
extern "C" {

static PyType_Slot Sbk_KCalendarCore_MemoryCalendar_slots[] = {
    {Py_tp_base,        nullptr}, // inserted by introduceWrapperType
    {Py_tp_dealloc,     reinterpret_cast<void *>(&SbkDeallocWrapper)},
    {Py_tp_setattro,    reinterpret_cast<void *>(Sbk_KCalendarCore_MemoryCalendar_setattro)},
    {Py_tp_traverse,    reinterpret_cast<void *>(Sbk_KCalendarCore_MemoryCalendar_traverse)},
    {Py_tp_clear,       reinterpret_cast<void *>(Sbk_KCalendarCore_MemoryCalendar_clear)},
    {Py_tp_methods,     reinterpret_cast<void *>(Sbk_KCalendarCore_MemoryCalendar_methods)},
    {Py_tp_init,        reinterpret_cast<void *>(Sbk_KCalendarCore_MemoryCalendar_Init)},
    {Py_tp_new,         reinterpret_cast<void *>(SbkObject_tp_new)},
    {0, nullptr}
};
static PyType_Spec Sbk_KCalendarCore_MemoryCalendar_spec = {
    "1:KCalendarCore.KCalendarCore.MemoryCalendar",
    sizeof(SbkObject),
    0,
    Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
    Sbk_KCalendarCore_MemoryCalendar_slots
};

} //extern "C"

static void *Sbk_KCalendarCore_MemoryCalendar_typeDiscovery([[maybe_unused]] void *cptr, [[maybe_unused]] PyTypeObject *instanceType)
{
    if (instanceType == Shiboken::SbkType< ::QObject >())
        return dynamic_cast< ::KCalendarCore::MemoryCalendar *>(reinterpret_cast< ::QObject *>(cptr));
    if (instanceType == Shiboken::SbkType< ::KCalendarCore::CustomProperties >())
        return dynamic_cast< ::KCalendarCore::MemoryCalendar *>(reinterpret_cast< ::KCalendarCore::CustomProperties *>(cptr));
    if (instanceType == Shiboken::SbkType< ::KCalendarCore::IncidenceBase::IncidenceObserver >())
        return dynamic_cast< ::KCalendarCore::MemoryCalendar *>(reinterpret_cast< ::KCalendarCore::IncidenceBase::IncidenceObserver *>(cptr));
    return {};
}


// Type conversion functions.

// Python to C++ pointer conversion - returns the C++ object of the Python wrapper (keeps object identity).
static void MemoryCalendar_PythonToCpp_MemoryCalendar_PTR(PyObject *pyIn, void *cppOut)
{
    Shiboken::Conversions::pythonToCppPointer(Sbk_KCalendarCore_MemoryCalendar_TypeF(), pyIn, cppOut);
}
static PythonToCppFunc is_MemoryCalendar_PythonToCpp_MemoryCalendar_PTR_Convertible(PyObject *pyIn)
{
    if (pyIn == Py_None)
        return Shiboken::Conversions::nonePythonToCppNullPtr;
    if (PyObject_TypeCheck(pyIn, Sbk_KCalendarCore_MemoryCalendar_TypeF()))
        return MemoryCalendar_PythonToCpp_MemoryCalendar_PTR;
    return {};
}

// C++ to Python pointer conversion - tries to find the Python wrapper for the C++ object (keeps object identity).
static PyObject *MemoryCalendar_PTR_CppToPython_MemoryCalendar(const void *cppIn)
{
    return PySide::getWrapperForQObject(reinterpret_cast<::KCalendarCore::MemoryCalendar *>(const_cast<void *>(cppIn)), Sbk_KCalendarCore_MemoryCalendar_TypeF());

}

// The signatures string for the functions.
// Multiple signatures have their index "n:" in front.
#if PYSIDE6_COMOPT_COMPRESS == 0
static const char *KCalendarCore_MemoryCalendar_SignatureStrings[] = {
    "1:KCalendarCore.KCalendarCore.MemoryCalendar(self,timeZoneId:typing.Union[PySide6.QtCore.QByteArray, char*])",
    "0:KCalendarCore.KCalendarCore.MemoryCalendar(self,timeZone:typing.Union[PySide6.QtCore.QTimeZone, PySide6.QtCore.QTimeZone.Initialization])",
    "KCalendarCore.KCalendarCore.MemoryCalendar.doSetTimeZone(self,timeZone:typing.Union[PySide6.QtCore.QTimeZone, PySide6.QtCore.QTimeZone.Initialization])",
    "KCalendarCore.KCalendarCore.MemoryCalendar.incidenceUpdate(self,uid:QString,recurrenceId:PySide6.QtCore.QDateTime)",
    "KCalendarCore.KCalendarCore.MemoryCalendar.incidenceUpdated(self,uid:QString,recurrenceId:PySide6.QtCore.QDateTime)",
    "KCalendarCore.KCalendarCore.MemoryCalendar.setUpdateLastModifiedOnChange(self,update:bool)",
    "KCalendarCore.KCalendarCore.MemoryCalendar.updateLastModifiedOnChange(self)->bool",
    "KCalendarCore.KCalendarCore.MemoryCalendar.virtual_hook(self,id:int,data:void)",
    nullptr}; // Sentinel
#else
static constexpr size_t KCalendarCore_MemoryCalendar_SignatureByteSize = 249;
static constexpr uint8_t KCalendarCore_MemoryCalendar_SignatureBytes[249] = {
    0x78, 0xda, 0xcd, 0x91, 0xb1, 0x4e, 0xc3, 0x40, 0x0c, 0x86, 0xf7, 0x3e, 0x45, 0x47, 0x82, 0x42,
    0x04, 0x0b, 0x43, 0x06, 0x24, 0x48, 0x97, 0xaa, 0x54, 0x10, 0x85, 0x2e, 0x20, 0x84, 0x4c, 0xce,
    0x6d, 0x2c, 0xae, 0x76, 0xe5, 0x38, 0x95, 0xc2, 0xd3, 0x73, 0x69, 0x9b, 0x01, 0x24, 0xaa, 0x16,
    0x24, 0xc4, 0x78, 0x67, 0xfb, 0xfb, 0x3f, 0xdf, 0x5d, 0xa4, 0x93, 0x0c, 0x3c, 0xb2, 0x03, 0xcd,
    0x44, 0x31, 0xf9, 0x7c, 0x9a, 0xe2, 0x52, 0xb4, 0xed, 0xaf, 0x4e, 0x6a, 0xf4, 0xf3, 0xd8, 0x68,
    0x89, 0x8f, 0xc2, 0x38, 0x76, 0xa9, 0xb5, 0x2b, 0xe2, 0x45, 0x32, 0x63, 0x12, 0x7e, 0xba, 0x6f,
    0x0b, 0x72, 0x78, 0x99, 0xe4, 0xb6, 0x19, 0xcd, 0x6f, 0x5a, 0xc3, 0x6b, 0x55, 0x68, 0xe3, 0x61,
    0x59, 0x81, 0x9e, 0x3e, 0x47, 0x83, 0xf3, 0x1f, 0x87, 0xed, 0x8f, 0x7a, 0xd8, 0x75, 0xc5, 0xc3,
    0xef, 0x2a, 0xc9, 0x98, 0xc9, 0x08, 0x3c, 0xbd, 0x83, 0x05, 0x42, 0x70, 0x39, 0xdc, 0x24, 0x71,
    0x52, 0xa0, 0xf5, 0xa4, 0x7f, 0xe4, 0x45, 0x5c, 0x06, 0x28, 0x97, 0x38, 0x5b, 0x39, 0xb0, 0x9d,
    0x59, 0x43, 0x2e, 0xcd, 0x0b, 0xd3, 0x60, 0x15, 0x2b, 0x96, 0x8d, 0x6a, 0xd7, 0x11, 0x3e, 0xeb,
    0xab, 0xc2, 0x28, 0x8c, 0x74, 0x1a, 0xbf, 0x89, 0x74, 0x7f, 0x91, 0x59, 0xa3, 0x6d, 0xd3, 0x6e,
    0xa1, 0xb6, 0xa9, 0x38, 0x9a, 0x13, 0xba, 0x3b, 0xce, 0x2a, 0xe0, 0x45, 0xbf, 0xf4, 0xa6, 0x9e,
    0xbe, 0x8a, 0xf8, 0xa3, 0xd0, 0xcd, 0x7e, 0x6e, 0x74, 0x76, 0xd5, 0x21, 0x8f, 0x21, 0xae, 0x49,
    0xad, 0x01, 0xff, 0x52, 0x89, 0xbc, 0x6d, 0xdd, 0xc2, 0xdb, 0x10, 0x5b, 0x1c, 0x82, 0x20, 0x5d,
    0x0b, 0xb9, 0x68, 0xf0, 0x01, 0xb4, 0x1e, 0x44, 0xd0
};
#endif

PyTypeObject *init_KCalendarCore_MemoryCalendar(PyObject *enclosingClass)
{
    auto &typeStruct = SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_MemoryCalendar_IDX];
    if (typeStruct.type != nullptr)
        return typeStruct.type;

    auto *base1 = reinterpret_cast<PyObject *>(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_Calendar_IDX]));
    Shiboken::AutoDecRef Sbk_KCalendarCore_MemoryCalendar_Type_bases(PyTuple_Pack(1, base1));

    PyTypeObject *pyType = Shiboken::ObjectType::introduceWrapperType(
        enclosingClass,
        "MemoryCalendar",
        "KCalendarCore::MemoryCalendar*",
        &Sbk_KCalendarCore_MemoryCalendar_spec,
        &Shiboken::callCppDestructor< KCalendarCore::MemoryCalendar >,
        Sbk_KCalendarCore_MemoryCalendar_Type_bases.object(),
        Shiboken::ObjectType::WrapperFlags::InnerClass);
#if PYSIDE6_COMOPT_COMPRESS == 0
    InitSignatureStrings(pyType, KCalendarCore_MemoryCalendar_SignatureStrings);
#else
    InitSignatureBytes(pyType, KCalendarCore_MemoryCalendar_SignatureBytes, KCalendarCore_MemoryCalendar_SignatureByteSize);
#endif
    SbkObjectType_SetPropertyStrings(pyType, Sbk_KCalendarCore_MemoryCalendar_PropertyStrings);
    typeStruct.type = pyType;

    // Register Converter
    SbkConverter *converter = Shiboken::Conversions::createConverter(pyType,
        MemoryCalendar_PythonToCpp_MemoryCalendar_PTR,
        is_MemoryCalendar_PythonToCpp_MemoryCalendar_PTR_Convertible,
        MemoryCalendar_PTR_CppToPython_MemoryCalendar);

    Shiboken::Conversions::registerConverterName(converter, "KCalendarCore::MemoryCalendar");
    Shiboken::Conversions::registerConverterName(converter, "KCalendarCore::MemoryCalendar*");
    Shiboken::Conversions::registerConverterName(converter, "KCalendarCore::MemoryCalendar&");
    Shiboken::Conversions::registerConverterAlias(converter, "MemoryCalendar");
    Shiboken::Conversions::registerConverterAlias(converter, "MemoryCalendar*");
    Shiboken::Conversions::registerConverterAlias(converter, "MemoryCalendar&");
    Shiboken::Conversions::registerConverterName(converter, typeid(::KCalendarCore::MemoryCalendar).name());
    Shiboken::Conversions::registerConverterName(converter, typeid(MemoryCalendarWrapper).name());

    MultipleInheritanceInitFunction func = Shiboken::ObjectType::getMultipleInheritanceFunction(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_Calendar_IDX]));
    Shiboken::ObjectType::setMultipleInheritanceFunction(Sbk_KCalendarCore_MemoryCalendar_TypeF(), func);
    Shiboken::ObjectType::setCastFunction(Sbk_KCalendarCore_MemoryCalendar_TypeF(), &Sbk_KCalendarCore_MemoryCalendarSpecialCastFunction);
    Shiboken::ObjectType::setTypeDiscoveryFunctionV2(pyType, &Sbk_KCalendarCore_MemoryCalendar_typeDiscovery);

    Shiboken::ObjectType::setSubTypeInitHook(pyType, &PySide::initQObjectSubType);
    PySide::initDynamicMetaObject(pyType, &::KCalendarCore::MemoryCalendar::staticMetaObject, sizeof(MemoryCalendarWrapper));

    return pyType;
}
