
// 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 <pysideqenum.h>
#include <pysideutils.h>
#include <feature_select.h>
QT_WARNING_DISABLE_DEPRECATED


// module include
#include "kcalendarcore_python.h"

// main header
#include "kcalendarcore_vcalformat_wrapper.h"

// Argument includes
#include <QString>
#include <attendee.h>
#include <qbytearray.h>
#include <qdatetime.h>

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

using namespace KCalendarCore;

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

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

VCalFormatWrapper::VCalFormatWrapper()
{
}

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

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

extern "C" {
static int
Sbk_KCalendarCore_VCalFormat_Init(PyObject *self, [[maybe_unused]] 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::VCalFormat >()))
        return -1;

    VCalFormatWrapper *cptr{};
    Shiboken::PythonContextMarker pcm;


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

    // Call function/method
    {

        // VCalFormat::VCalFormat()
        cptr = new VCalFormatWrapper();
    }

    if (Shiboken::Errors::occurred() != nullptr || !Shiboken::Object::setCppPointer(sbkSelf, Shiboken::SbkType< KCalendarCore::VCalFormat >(), cptr)) {
        delete cptr;
        return -1;
    }
    Shiboken::Object::setValidCpp(sbkSelf, true);
    Shiboken::Object::setHasCppWrapper(sbkSelf, true);
    Shiboken::BindingManager::instance().registerWrapper(sbkSelf, cptr);


    return 1;
}

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

    // Overloaded function decisor
    // 0: VCalFormat::ISOToQDate(const QString&)->QDate
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QString_IDX], (pyArg)))) {
        overloadId = 0; // VCalFormat::ISOToQDate(const QString&)->QDate
    }

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

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

        if (Shiboken::Errors::occurred() == nullptr) {
            // VCalFormat::ISOToQDate(const QString&)->QDate
            QDate cppResult = cppSelf->ISOToQDate(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QDate_IDX]), &cppResult);
        }
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

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

    // Overloaded function decisor
    // 0: VCalFormat::ISOToQDateTime(const QString&)->QDateTime
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QString_IDX], (pyArg)))) {
        overloadId = 0; // VCalFormat::ISOToQDateTime(const QString&)->QDateTime
    }

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

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

        if (Shiboken::Errors::occurred() == nullptr) {
            // VCalFormat::ISOToQDateTime(const QString&)->QDateTime
            QDateTime cppResult = cppSelf->ISOToQDateTime(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QDateTime_IDX]), &cppResult);
        }
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

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

    // Overloaded function decisor
    // 0: VCalFormat::numFromDay(const QString&)->int
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QString_IDX], (pyArg)))) {
        overloadId = 0; // VCalFormat::numFromDay(const QString&)->int
    }

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

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

        if (Shiboken::Errors::occurred() == nullptr) {
            // VCalFormat::numFromDay(const QString&)->int
            int cppResult = cppSelf->numFromDay(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<int>(), &cppResult);
        }
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

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

    // Overloaded function decisor
    // 0: VCalFormat::parseDst(QByteArray&)const->QString
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QByteArray_IDX]), (pyArg)))) {
        overloadId = 0; // VCalFormat::parseDst(QByteArray&)const->QString
    }

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

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


        if (Shiboken::Errors::occurred() == nullptr) {
            // VCalFormat::parseDst(QByteArray&)const->QString
            QString cppResult = const_cast<const ::KCalendarCore::VCalFormat *>(cppSelf)->parseDst(*cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QString_IDX], &cppResult);
        }
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

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

    // Overloaded function decisor
    // 0: VCalFormat::parseTZ(const QByteArray&)const->QString
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QByteArray_IDX]), (pyArg)))) {
        overloadId = 0; // VCalFormat::parseTZ(const QByteArray&)const->QString
    }

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

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


        if (Shiboken::Errors::occurred() == nullptr) {
            // VCalFormat::parseTZ(const QByteArray&)const->QString
            QString cppResult = const_cast<const ::KCalendarCore::VCalFormat *>(cppSelf)->parseTZ(*cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QString_IDX], &cppResult);
        }
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

static PyObject *Sbk_KCalendarCore_VCalFormatFunc_parseTZOffsetISO8601(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::KCalendarCore::VCalFormat *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_VCalFormat_IDX]), reinterpret_cast<SbkObject *>(self)));
    PyObject *pyResult{};
    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, "parseTZOffsetISO8601", 2, 2, &(pyArgs[0]), &(pyArgs[1])) == 0)
        return {};


    // Overloaded function decisor
    // 0: VCalFormat::parseTZOffsetISO8601(const QString&,int&)->bool
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QString_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[1])))) {
        overloadId = 0; // VCalFormat::parseTZOffsetISO8601(const QString&,int&)->bool
    }

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

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

        if (Shiboken::Errors::occurred() == nullptr) {
            // VCalFormat::parseTZOffsetISO8601(const QString&,int&)->bool
            bool cppResult = cppSelf->parseTZOffsetISO8601(cppArg0, cppArg1);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

static PyObject *Sbk_KCalendarCore_VCalFormatFunc_qDateTimeToISO(PyObject *self, PyObject *args, [[maybe_unused]] PyObject *kwds)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::KCalendarCore::VCalFormat *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_VCalFormat_IDX]), reinterpret_cast<SbkObject *>(self)));
    PyObject *pyResult{};
    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
    errInfo.reset(Shiboken::checkInvalidArgumentCount(numArgs, 1, 2));
    if (!errInfo.isNull())
        return Shiboken::returnWrongArguments(args, "qDateTimeToISO", errInfo, SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_VCalFormat_IDX]);

    if (PyArg_ParseTuple(args, "|OO:qDateTimeToISO", &(pyArgs[0]), &(pyArgs[1])) == 0)
        return {};


    // Overloaded function decisor
    // 0: VCalFormat::qDateTimeToISO(const QDateTime&,bool=)->QString
    if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppReferenceConversion(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QDateTime_IDX]), (pyArgs[0])))) {
        if (numArgs == 1) {
            overloadId = 0; // qDateTimeToISO(QDateTime,bool)
        } else if (numArgs >= 2
            && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), (pyArgs[1])))) {
            overloadId = 0; // VCalFormat::qDateTimeToISO(const QDateTime&,bool=)->QString
        }
    }

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

    // Call function/method
    {
        if (kwds != nullptr && PyDict_Size(kwds) > 0) {
            static const Shiboken::ArgumentNameIndexMapping mapping[1] = {{"zulu", 1}};
            if (!Shiboken::parseKeywordArguments(kwds, mapping, 1, errInfo, pyArgs)
                || (pyArgs[1] != nullptr && !((pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), (pyArgs[1])))))) {
                Py_XINCREF(errInfo.object());
                return Shiboken::returnWrongArguments(args, "qDateTimeToISO", errInfo, SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_VCalFormat_IDX]);
            }
        }
        if (!Shiboken::Object::isValid(pyArgs[0]))
            return {};
        ::QDateTime cppArg0_local;
        ::QDateTime *cppArg0 = &cppArg0_local;
        if (pythonToCpp[0].isValue())
            pythonToCpp[0](pyArgs[0], &cppArg0_local);
        else
            pythonToCpp[0](pyArgs[0], &cppArg0);

        bool cppArg1 = true;
        if (pythonToCpp[1])
            pythonToCpp[1](pyArgs[1], &cppArg1);

        if (Shiboken::Errors::occurred() == nullptr) {
            // VCalFormat::qDateTimeToISO(const QDateTime&,bool=)->QString
            QString cppResult = cppSelf->qDateTimeToISO(*cppArg0, cppArg1);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QString_IDX], &cppResult);
        }
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

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

    // Overloaded function decisor
    // 0: VCalFormat::qDateToISO(const QDate&)->QString
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QDate_IDX]), (pyArg)))) {
        overloadId = 0; // VCalFormat::qDateToISO(const QDate&)->QString
    }

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

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


        if (Shiboken::Errors::occurred() == nullptr) {
            // VCalFormat::qDateToISO(const QDate&)->QString
            QString cppResult = cppSelf->qDateToISO(*cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QString_IDX], &cppResult);
        }
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

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

    // Overloaded function decisor
    // 0: VCalFormat::readStatus(const char*)const->KCalendarCore::Attendee::PartStat
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<const char *>(), (pyArg)))) {
        overloadId = 0; // VCalFormat::readStatus(const char*)const->KCalendarCore::Attendee::PartStat
    }

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

    // Call function/method
    {
        const char* cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (Shiboken::Errors::occurred() == nullptr) {
            // VCalFormat::readStatus(const char*)const->KCalendarCore::Attendee::PartStat
            KCalendarCore::Attendee::PartStat cppResult = const_cast<const ::KCalendarCore::VCalFormat *>(cppSelf)->readStatus(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Enum::getConverter(reinterpret_cast<SbkEnumType *>(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_Attendee_PartStat_IDX]))), &cppResult);
        }
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

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

    // Overloaded function decisor
    // 0: VCalFormat::writeStatus(KCalendarCore::Attendee::PartStat)const->QByteArray
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(Shiboken::Enum::getConverter(reinterpret_cast<SbkEnumType *>(Shiboken::Module::get(SbkKCalendarCoreTypeStructs[SBK_KCalendarCore_Attendee_PartStat_IDX]))), (pyArg)))) {
        overloadId = 0; // VCalFormat::writeStatus(KCalendarCore::Attendee::PartStat)const->QByteArray
    }

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

    // Call function/method
    {
        ::KCalendarCore::Attendee::PartStat cppArg0{KCalendarCore::Attendee::NeedsAction};
        pythonToCpp(pyArg, &cppArg0);

        if (Shiboken::Errors::occurred() == nullptr) {
            // VCalFormat::writeStatus(KCalendarCore::Attendee::PartStat)const->QByteArray
            QByteArray cppResult = const_cast<const ::KCalendarCore::VCalFormat *>(cppSelf)->writeStatus(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QByteArray_IDX]), &cppResult);
        }
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}


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

static PyMethodDef Sbk_KCalendarCore_VCalFormat_methods[] = {
    {"ISOToQDate", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_VCalFormatFunc_ISOToQDate), METH_O, nullptr},
    {"ISOToQDateTime", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_VCalFormatFunc_ISOToQDateTime), METH_O, nullptr},
    {"numFromDay", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_VCalFormatFunc_numFromDay), METH_O, nullptr},
    {"parseDst", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_VCalFormatFunc_parseDst), METH_O, nullptr},
    {"parseTZ", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_VCalFormatFunc_parseTZ), METH_O, nullptr},
    {"parseTZOffsetISO8601", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_VCalFormatFunc_parseTZOffsetISO8601), METH_VARARGS, nullptr},
    {"qDateTimeToISO", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_VCalFormatFunc_qDateTimeToISO), METH_VARARGS|METH_KEYWORDS, nullptr},
    {"qDateToISO", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_VCalFormatFunc_qDateToISO), METH_O, nullptr},
    {"readStatus", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_VCalFormatFunc_readStatus), METH_O, nullptr},
    {"writeStatus", reinterpret_cast<PyCFunction>(Sbk_KCalendarCore_VCalFormatFunc_writeStatus), METH_O, nullptr},
    {nullptr, nullptr, 0, nullptr} // Sentinel
};

} // extern "C"

static int Sbk_KCalendarCore_VCalFormat_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_VCalFormat_clear(PyObject *self)
{
    auto clearProc = reinterpret_cast<inquiry>(PyType_GetSlot(SbkObject_TypeF(), Py_tp_clear));
    ;
    return clearProc(self);
}

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

static PyType_Slot Sbk_KCalendarCore_VCalFormat_slots[] = {
    {Py_tp_base,        nullptr}, // inserted by introduceWrapperType
    {Py_tp_dealloc,     reinterpret_cast<void *>(&SbkDeallocWrapper)},
    {Py_tp_traverse,    reinterpret_cast<void *>(Sbk_KCalendarCore_VCalFormat_traverse)},
    {Py_tp_clear,       reinterpret_cast<void *>(Sbk_KCalendarCore_VCalFormat_clear)},
    {Py_tp_methods,     reinterpret_cast<void *>(Sbk_KCalendarCore_VCalFormat_methods)},
    {Py_tp_init,        reinterpret_cast<void *>(Sbk_KCalendarCore_VCalFormat_Init)},
    {Py_tp_new,         reinterpret_cast<void *>(SbkObject_tp_new)},
    {0, nullptr}
};
static PyType_Spec Sbk_KCalendarCore_VCalFormat_spec = {
    "1:KCalendarCore.KCalendarCore.VCalFormat",
    sizeof(SbkObject),
    0,
    Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
    Sbk_KCalendarCore_VCalFormat_slots
};

} //extern "C"

static void *Sbk_KCalendarCore_VCalFormat_typeDiscovery([[maybe_unused]] void *cptr, [[maybe_unused]] PyTypeObject *instanceType)
{
    if (instanceType == Shiboken::SbkType< ::KCalendarCore::CalFormat >())
        return dynamic_cast< ::KCalendarCore::VCalFormat *>(reinterpret_cast< ::KCalendarCore::CalFormat *>(cptr));
    return {};
}


// Type conversion functions.

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

// C++ to Python pointer conversion - tries to find the Python wrapper for the C++ object (keeps object identity).
static PyObject *VCalFormat_PTR_CppToPython_VCalFormat(const void *cppIn)
{
    auto *pyOut = reinterpret_cast<PyObject *>(Shiboken::BindingManager::instance().retrieveWrapper(cppIn, Sbk_KCalendarCore_VCalFormat_TypeF()));
    if (pyOut) {
        Py_INCREF(pyOut);
        return pyOut;
    }
    auto *tCppIn = reinterpret_cast<const ::KCalendarCore::VCalFormat *>(cppIn);
    const char *typeName = typeid(*tCppIn).name();
    return Shiboken::Object::newObjectForPointer(Sbk_KCalendarCore_VCalFormat_TypeF(), const_cast<void *>(cppIn), false, typeName);

}

// The signatures string for the functions.
// Multiple signatures have their index "n:" in front.
#if PYSIDE6_COMOPT_COMPRESS == 0
static const char *KCalendarCore_VCalFormat_SignatureStrings[] = {
    "KCalendarCore.KCalendarCore.VCalFormat(self)",
    "KCalendarCore.KCalendarCore.VCalFormat.ISOToQDate(self,dtStr:QString)->PySide6.QtCore.QDate",
    "KCalendarCore.KCalendarCore.VCalFormat.ISOToQDateTime(self,dtStr:QString)->PySide6.QtCore.QDateTime",
    "KCalendarCore.KCalendarCore.VCalFormat.numFromDay(self,day:QString)->int",
    "KCalendarCore.KCalendarCore.VCalFormat.parseDst(self,timezone:typing.Union[PySide6.QtCore.QByteArray, char*])->QString",
    "KCalendarCore.KCalendarCore.VCalFormat.parseTZ(self,timezone:typing.Union[PySide6.QtCore.QByteArray, char*])->QString",
    "KCalendarCore.KCalendarCore.VCalFormat.parseTZOffsetISO8601(self,s:QString,result:int)->bool",
    "KCalendarCore.KCalendarCore.VCalFormat.qDateTimeToISO(self,date:PySide6.QtCore.QDateTime,zulu:bool=true)->QString",
    "KCalendarCore.KCalendarCore.VCalFormat.qDateToISO(self,date:PySide6.QtCore.QDate)->QString",
    "KCalendarCore.KCalendarCore.VCalFormat.readStatus(self,s:char*)->KCalendarCore.KCalendarCore.Attendee.PartStat",
    "KCalendarCore.KCalendarCore.VCalFormat.writeStatus(self,status:KCalendarCore.KCalendarCore.Attendee.PartStat)->PySide6.QtCore.QByteArray",
    nullptr}; // Sentinel
#else
static constexpr size_t KCalendarCore_VCalFormat_SignatureByteSize = 288;
static constexpr uint8_t KCalendarCore_VCalFormat_SignatureBytes[288] = {
    0x78, 0xda, 0xc5, 0x93, 0x51, 0x4b, 0xc3, 0x30, 0x10, 0x80, 0xdf, 0xf7, 0x2b, 0x7c, 0x74, 0x52,
    0x8b, 0xbe, 0x0c, 0x09, 0x28, 0xcc, 0x95, 0x81, 0xf4, 0x61, 0x2b, 0xad, 0x3e, 0x28, 0x3e, 0x9c,
    0xf6, 0xaa, 0x81, 0x36, 0x99, 0x97, 0x0b, 0x92, 0xfd, 0x7a, 0xd3, 0x6e, 0x15, 0x27, 0x2a, 0xc9,
    0x93, 0x2f, 0x25, 0x07, 0x77, 0xdf, 0x77, 0xb9, 0x4b, 0xf3, 0x05, 0xb4, 0xa8, 0x6a, 0xa0, 0x85,
    0x26, 0x4c, 0xf3, 0x83, 0xe8, 0xce, 0x47, 0x4b, 0x4d, 0x1d, 0xf0, 0xb1, 0xc1, 0xb6, 0x99, 0x4e,
    0xf2, 0xa0, 0xe4, 0xf4, 0xa6, 0x5c, 0x55, 0xba, 0xc8, 0x80, 0x71, 0xa8, 0x4b, 0x6a, 0x2e, 0x99,
    0x44, 0xe1, 0x3f, 0x52, 0xbd, 0x4c, 0x4f, 0xaf, 0xd6, 0xae, 0x94, 0x35, 0xce, 0xd2, 0x82, 0x87,
    0xca, 0x21, 0x33, 0x9e, 0x5d, 0xc9, 0x2e, 0x82, 0xdf, 0x67, 0x87, 0x3a, 0x94, 0xed, 0x96, 0xa4,
    0xbb, 0x0c, 0xdc, 0x9e, 0x0f, 0xee, 0x0b, 0x5d, 0x2a, 0x0e, 0x05, 0x6d, 0x80, 0x0c, 0x66, 0x66,
    0x37, 0xbe, 0x84, 0x7d, 0x0b, 0x5b, 0xad, 0x50, 0xb0, 0xdb, 0x78, 0x54, 0x7a, 0xab, 0xa4, 0x56,
    0x0f, 0xdf, 0x9b, 0xbd, 0x76, 0x8c, 0x73, 0x22, 0x70, 0xc9, 0xd1, 0xf3, 0x2b, 0xd0, 0xc9, 0xa3,
    0x57, 0xee, 0xe5, 0x51, 0xda, 0xea, 0xfe, 0x7f, 0xac, 0xab, 0xa6, 0x31, 0xc8, 0x7e, 0x4d, 0x17,
    0xb3, 0xb3, 0xf3, 0x5d, 0x0b, 0x66, 0x9c, 0x5e, 0x42, 0x68, 0x6c, 0xcb, 0xc2, 0x8f, 0xd0, 0xf3,
    0x9f, 0xb4, 0x6e, 0x43, 0xe1, 0x6f, 0xe3, 0x0e, 0x2b, 0xed, 0xd1, 0xe3, 0x5a, 0x18, 0xc5, 0x6f,
    0xbb, 0x4e, 0xb6, 0xb6, 0xb5, 0xa2, 0x57, 0x5c, 0x32, 0x59, 0x8c, 0xbf, 0xce, 0xce, 0x18, 0x60,
    0x8b, 0x47, 0x13, 0x42, 0x5d, 0x32, 0xb0, 0x35, 0xe3, 0x7c, 0x86, 0x99, 0x7b, 0xd0, 0x5f, 0x80,
    0x39, 0xb3, 0x0f, 0x10, 0xd3, 0x35, 0x10, 0xf7, 0xe5, 0xa1, 0xba, 0x77, 0x92, 0x8c, 0x07, 0xbe,
    0xe1, 0x2c, 0xa2, 0x64, 0x3f, 0xfc, 0x56, 0x9f, 0x6f, 0x66, 0xf2, 0x01, 0x95, 0x37, 0x88, 0xda
};
#endif

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

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

    PyTypeObject *pyType = Shiboken::ObjectType::introduceWrapperType(
        enclosingClass,
        "VCalFormat",
        "KCalendarCore::VCalFormat*",
        &Sbk_KCalendarCore_VCalFormat_spec,
        &Shiboken::callCppDestructor< KCalendarCore::VCalFormat >,
        Sbk_KCalendarCore_VCalFormat_Type_bases.object(),
        Shiboken::ObjectType::WrapperFlags::InnerClass);
#if PYSIDE6_COMOPT_COMPRESS == 0
    InitSignatureStrings(pyType, KCalendarCore_VCalFormat_SignatureStrings);
#else
    InitSignatureBytes(pyType, KCalendarCore_VCalFormat_SignatureBytes, KCalendarCore_VCalFormat_SignatureByteSize);
#endif
    SbkObjectType_SetPropertyStrings(pyType, Sbk_KCalendarCore_VCalFormat_PropertyStrings);
    typeStruct.type = pyType;

    // Register Converter
    SbkConverter *converter = Shiboken::Conversions::createConverter(pyType,
        VCalFormat_PythonToCpp_VCalFormat_PTR,
        is_VCalFormat_PythonToCpp_VCalFormat_PTR_Convertible,
        VCalFormat_PTR_CppToPython_VCalFormat);

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

    Shiboken::ObjectType::setTypeDiscoveryFunctionV2(pyType, &Sbk_KCalendarCore_VCalFormat_typeDiscovery);

    qRegisterMetaType< ::KCalendarCore::VCalFormat *>();

    return pyType;
}
