
// 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 "akonadicore_python.h"

// main header
#include "akonadi_specialcollectionattribute_wrapper.h"

// Wrappers providing overrides
#include "akonadi_exception_wrapper.h"
#include "akonadi_attribute_wrapper.h"

// Argument includes
#include <qbytearray.h>
#include <specialcollectionattribute.h>

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

using namespace Akonadi;

extern "C" {
static PyTypeObject *Sbk_Akonadi_SpecialCollectionAttribute_TypeF(void)
{
    return SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX].type;
}
} // extern "C"

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

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

SpecialCollectionAttributeWrapper::SpecialCollectionAttributeWrapper(const ::QByteArray & type) : Akonadi::SpecialCollectionAttribute(type)
{
}

::Akonadi::SpecialCollectionAttribute * SpecialCollectionAttributeWrapper::clone() const
{
    static const char *funcName = "clone";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_Akonadi_SpecialCollectionAttribute_TypeF(), gil, funcName, m_PyMethodCache[0], nameCache));
    if (pyOverride.isNull()) {
        return this->::Akonadi::SpecialCollectionAttribute::clone();
    }
    return sbk_o_clone("SpecialCollectionAttribute", funcName, gil, pyOverride);
}

::Akonadi::SpecialCollectionAttribute * SpecialCollectionAttributeWrapper::sbk_o_clone([[maybe_unused]] const char *ownerClassName, [[maybe_unused]] const char *funcName, [[maybe_unused]] Shiboken::GilState &gil, [[maybe_unused]] const Shiboken::AutoDecRef &pyOverride)
{
#if defined(PYPY_VERSION)
    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));
#endif

#if !defined(PYPY_VERSION)
    Shiboken::AutoDecRef pyResult(PyObject_CallNoArgs(pyOverride));
#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 nullptr;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppPointerConversion(Shiboken::Module::get(SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX]), pyResult);
    if (!pythonToCpp) {
        Shiboken::Warnings::warnInvalidReturnValue(ownerClassName, funcName, PepType_GetFullyQualifiedNameStr(Shiboken::SbkType< Akonadi::SpecialCollectionAttribute >()), Py_TYPE(pyResult)->tp_name);
        return nullptr;
    }
    ::Akonadi::SpecialCollectionAttribute *cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

void SpecialCollectionAttributeWrapper::deserialize(const ::QByteArray & data)
{
    static const char *funcName = "deserialize";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_Akonadi_SpecialCollectionAttribute_TypeF(), gil, funcName, m_PyMethodCache[1], nameCache));
    if (pyOverride.isNull()) {
        return this->::Akonadi::SpecialCollectionAttribute::deserialize(data);
    }
    AttributeWrapper::sbk_o_deserialize("SpecialCollectionAttribute", funcName, gil, pyOverride, data);
}

::QByteArray SpecialCollectionAttributeWrapper::serialized() const
{
    static const char *funcName = "serialized";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_Akonadi_SpecialCollectionAttribute_TypeF(), gil, funcName, m_PyMethodCache[2], nameCache));
    if (pyOverride.isNull()) {
        return this->::Akonadi::SpecialCollectionAttribute::serialized();
    }
    return ExceptionWrapper::sbk_o_type("SpecialCollectionAttribute", funcName, gil, pyOverride);
}

::QByteArray SpecialCollectionAttributeWrapper::type() const
{
    static const char *funcName = "type";
    static PyObject *nameCache[2] = {};
    Shiboken::GilState gil(false);
    Shiboken::AutoDecRef pyOverride(Sbk_GetPyOverride(this, Sbk_Akonadi_SpecialCollectionAttribute_TypeF(), gil, funcName, m_PyMethodCache[3], nameCache));
    if (pyOverride.isNull()) {
        return this->::Akonadi::SpecialCollectionAttribute::type();
    }
    return ExceptionWrapper::sbk_o_type("SpecialCollectionAttribute", funcName, gil, pyOverride);
}

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

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

extern "C" {
static int
Sbk_Akonadi_SpecialCollectionAttribute_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< ::Akonadi::SpecialCollectionAttribute >()))
        return -1;

    SpecialCollectionAttributeWrapper *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
    errInfo.reset(Shiboken::checkInvalidArgumentCount(numArgs, 0, 1));
    if (!errInfo.isNull())
        return Shiboken::returnWrongArguments_MinusOne(args, "__init__", errInfo, SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX]);

    if (PyArg_ParseTuple(args, "|O:SpecialCollectionAttribute", &(pyArgs[0])) == 0)
        return -1;


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

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

    // Resolve keyword arguments
    {
        if (kwds != nullptr && PyDict_Size(kwds) > 0) {
            static const Shiboken::ArgumentNameIndexMapping mapping[1] = {{"type", 0}};
            if (!Shiboken::parseKeywordArguments(kwds, mapping, 1, errInfo, pyArgs)
                || (pyArgs[0] != nullptr && !((pythonToCpp[0] = Shiboken::Conversions::pythonToCppReferenceConversion(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QByteArray_IDX]), (pyArgs[0])))))) {
                Py_XINCREF(errInfo.object());
                return Shiboken::returnWrongArguments_MinusOne(args, "__init__", errInfo, SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX]);
            }
        }
    }

    // PyMI support
    Shiboken::callInheritedInit(self, args, errInfo.isNull() ? kwds : errInfo.object(), SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX]);
    if (Shiboken::Errors::occurred() != nullptr)
        return -1;

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

        if (Shiboken::Errors::occurred() == nullptr) {
            // SpecialCollectionAttribute::SpecialCollectionAttribute(const QByteArray&=)
            cptr = new SpecialCollectionAttributeWrapper(*cppArg0);
        }
    }

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

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


    return 1;
}

static PyObject *Sbk_Akonadi_SpecialCollectionAttributeFunc_clone(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::Akonadi::SpecialCollectionAttribute *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX]), reinterpret_cast<SbkObject *>(self)));
    PyObject *pyResult{};
    Shiboken::PythonContextMarker pcm;

    // Call function/method
    {

        // Attribute::clone()const->Akonadi::SpecialCollectionAttribute*
        Akonadi::SpecialCollectionAttribute * cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
            ? const_cast<const ::Akonadi::SpecialCollectionAttribute *>(cppSelf)->::Akonadi::SpecialCollectionAttribute::clone()
            : const_cast<const ::Akonadi::SpecialCollectionAttribute *>(cppSelf)->clone();
        pyResult = Shiboken::Conversions::pointerToPython(Shiboken::Module::get(SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX]), cppResult);
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

static PyObject *Sbk_Akonadi_SpecialCollectionAttributeFunc_collectionType(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::Akonadi::SpecialCollectionAttribute *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX]), reinterpret_cast<SbkObject *>(self)));
    PyObject *pyResult{};
    Shiboken::PythonContextMarker pcm;

    // Call function/method
    {

        // SpecialCollectionAttribute::collectionType()const->QByteArray
        QByteArray cppResult = const_cast<const ::Akonadi::SpecialCollectionAttribute *>(cppSelf)->collectionType();
        pyResult = Shiboken::Conversions::copyToPython(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QByteArray_IDX]), &cppResult);
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

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

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

    // Function signature not found.
    if (overloadId == -1)
        return Shiboken::returnWrongArguments(pyArg, "deserialize", SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_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) {
            // Attribute::deserialize(const QByteArray&)
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::Akonadi::SpecialCollectionAttribute::deserialize(*cppArg0)
                : cppSelf->deserialize(*cppArg0);
        }
    }

     return Sbk_ReturnFromPython_None();
}

static PyObject *Sbk_Akonadi_SpecialCollectionAttributeFunc_serialized(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::Akonadi::SpecialCollectionAttribute *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX]), reinterpret_cast<SbkObject *>(self)));
    PyObject *pyResult{};
    Shiboken::PythonContextMarker pcm;

    // Call function/method
    {

        // Attribute::serialized()const->QByteArray
        QByteArray cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
            ? const_cast<const ::Akonadi::SpecialCollectionAttribute *>(cppSelf)->::Akonadi::SpecialCollectionAttribute::serialized()
            : const_cast<const ::Akonadi::SpecialCollectionAttribute *>(cppSelf)->serialized();
        pyResult = Shiboken::Conversions::copyToPython(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QByteArray_IDX]), &cppResult);
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}

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

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

    // Function signature not found.
    if (overloadId == -1)
        return Shiboken::returnWrongArguments(pyArg, "setCollectionType", SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_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) {
            // SpecialCollectionAttribute::setCollectionType(const QByteArray&)
            cppSelf->setCollectionType(*cppArg0);
        }
    }

     return Sbk_ReturnFromPython_None();
}

static PyObject *Sbk_Akonadi_SpecialCollectionAttributeFunc_type(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    [[maybe_unused]] auto *cppSelf = reinterpret_cast< ::Akonadi::SpecialCollectionAttribute *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX]), reinterpret_cast<SbkObject *>(self)));
    PyObject *pyResult{};
    Shiboken::PythonContextMarker pcm;

    // Call function/method
    {

        // Attribute::type()const->QByteArray
        QByteArray cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
            ? const_cast<const ::Akonadi::SpecialCollectionAttribute *>(cppSelf)->::Akonadi::SpecialCollectionAttribute::type()
            : const_cast<const ::Akonadi::SpecialCollectionAttribute *>(cppSelf)->type();
        pyResult = Shiboken::Conversions::copyToPython(Shiboken::Module::get(SbkPySide6_QtCoreTypeStructs[SBK_QByteArray_IDX]), &cppResult);
    }

    return Sbk_ReturnFromPython_Result(pyResult);
}


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

static PyMethodDef Sbk_Akonadi_SpecialCollectionAttribute_methods[] = {
    {"clone", reinterpret_cast<PyCFunction>(Sbk_Akonadi_SpecialCollectionAttributeFunc_clone), METH_NOARGS, nullptr},
    {"collectionType", reinterpret_cast<PyCFunction>(Sbk_Akonadi_SpecialCollectionAttributeFunc_collectionType), METH_NOARGS, nullptr},
    {"deserialize", reinterpret_cast<PyCFunction>(Sbk_Akonadi_SpecialCollectionAttributeFunc_deserialize), METH_O, nullptr},
    {"serialized", reinterpret_cast<PyCFunction>(Sbk_Akonadi_SpecialCollectionAttributeFunc_serialized), METH_NOARGS, nullptr},
    {"setCollectionType", reinterpret_cast<PyCFunction>(Sbk_Akonadi_SpecialCollectionAttributeFunc_setCollectionType), METH_O, nullptr},
    {"type", reinterpret_cast<PyCFunction>(Sbk_Akonadi_SpecialCollectionAttributeFunc_type), METH_NOARGS, nullptr},
    {nullptr, nullptr, 0, nullptr} // Sentinel
};

static int Sbk_Akonadi_SpecialCollectionAttribute_setattro(PyObject *self, PyObject *name, PyObject *value)
{
    PySide::Feature::Select(self);
    if (value != nullptr && PyCallable_Check(value) != 0) {
        auto plain_inst = reinterpret_cast< ::Akonadi::SpecialCollectionAttribute *>(Shiboken::Conversions::cppPointer(Shiboken::Module::get(SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX]), reinterpret_cast<SbkObject *>(self)));
        auto *inst = dynamic_cast<SpecialCollectionAttributeWrapper *>(plain_inst);
        if (inst != nullptr)
            inst->resetPyMethodCache();
    }
    return PyObject_GenericSetAttr(self, name, value);
}

} // extern "C"

static int Sbk_Akonadi_SpecialCollectionAttribute_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_Akonadi_SpecialCollectionAttribute_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_Akonadi_SpecialCollectionAttribute_slots[] = {
    {Py_tp_base,        nullptr}, // inserted by introduceWrapperType
    {Py_tp_dealloc,     reinterpret_cast<void *>(&SbkDeallocWrapper)},
    {Py_tp_setattro,    reinterpret_cast<void *>(Sbk_Akonadi_SpecialCollectionAttribute_setattro)},
    {Py_tp_traverse,    reinterpret_cast<void *>(Sbk_Akonadi_SpecialCollectionAttribute_traverse)},
    {Py_tp_clear,       reinterpret_cast<void *>(Sbk_Akonadi_SpecialCollectionAttribute_clear)},
    {Py_tp_methods,     reinterpret_cast<void *>(Sbk_Akonadi_SpecialCollectionAttribute_methods)},
    {Py_tp_init,        reinterpret_cast<void *>(Sbk_Akonadi_SpecialCollectionAttribute_Init)},
    {Py_tp_new,         reinterpret_cast<void *>(SbkObject_tp_new)},
    {0, nullptr}
};
static PyType_Spec Sbk_Akonadi_SpecialCollectionAttribute_spec = {
    "1:AkonadiCore.Akonadi.SpecialCollectionAttribute",
    sizeof(SbkObject),
    0,
    Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
    Sbk_Akonadi_SpecialCollectionAttribute_slots
};

} //extern "C"

static void *Sbk_Akonadi_SpecialCollectionAttribute_typeDiscovery([[maybe_unused]] void *cptr, [[maybe_unused]] PyTypeObject *instanceType)
{
    if (instanceType == Shiboken::SbkType< ::Akonadi::Attribute >())
        return dynamic_cast< ::Akonadi::SpecialCollectionAttribute *>(reinterpret_cast< ::Akonadi::Attribute *>(cptr));
    return {};
}


// Type conversion functions.

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

// C++ to Python pointer conversion - tries to find the Python wrapper for the C++ object (keeps object identity).
static PyObject *SpecialCollectionAttribute_PTR_CppToPython_SpecialCollectionAttribute(const void *cppIn)
{
    auto *pyOut = reinterpret_cast<PyObject *>(Shiboken::BindingManager::instance().retrieveWrapper(cppIn, Sbk_Akonadi_SpecialCollectionAttribute_TypeF()));
    if (pyOut) {
        Py_INCREF(pyOut);
        return pyOut;
    }
    auto *tCppIn = reinterpret_cast<const ::Akonadi::SpecialCollectionAttribute *>(cppIn);
    const char *typeName = typeid(*tCppIn).name();
    return Shiboken::Object::newObjectForPointer(Sbk_Akonadi_SpecialCollectionAttribute_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 *Akonadi_SpecialCollectionAttribute_SignatureStrings[] = {
    "AkonadiCore.Akonadi.SpecialCollectionAttribute(self,type:typing.Union[PySide6.QtCore.QByteArray, char*]=QByteArray())",
    "AkonadiCore.Akonadi.SpecialCollectionAttribute.clone(self)->AkonadiCore.Akonadi.SpecialCollectionAttribute",
    "AkonadiCore.Akonadi.SpecialCollectionAttribute.collectionType(self)->PySide6.QtCore.QByteArray",
    "AkonadiCore.Akonadi.SpecialCollectionAttribute.deserialize(self,data:typing.Union[PySide6.QtCore.QByteArray, char*])",
    "AkonadiCore.Akonadi.SpecialCollectionAttribute.serialized(self)->PySide6.QtCore.QByteArray",
    "AkonadiCore.Akonadi.SpecialCollectionAttribute.setCollectionType(self,type:typing.Union[PySide6.QtCore.QByteArray, char*])",
    "AkonadiCore.Akonadi.SpecialCollectionAttribute.type(self)->PySide6.QtCore.QByteArray",
    nullptr}; // Sentinel
#else
static constexpr size_t Akonadi_SpecialCollectionAttribute_SignatureByteSize = 179;
static constexpr uint8_t Akonadi_SpecialCollectionAttribute_SignatureBytes[179] = {
    0x78, 0xda, 0xad, 0x92, 0xc1, 0x0a, 0xc2, 0x30, 0x0c, 0x86, 0xef, 0x3e, 0x85, 0xc7, 0x4d, 0x66,
    0x8f, 0x1e, 0x04, 0x85, 0xba, 0x17, 0x70, 0x4c, 0x4f, 0xe2, 0xa1, 0xb6, 0x51, 0xc3, 0x4a, 0x3b,
    0xba, 0x78, 0xa8, 0x4f, 0x6f, 0x71, 0x3a, 0x0f, 0x22, 0x18, 0xf1, 0x12, 0x42, 0x42, 0xf2, 0xf1,
    0xff, 0x89, 0x6c, 0xbc, 0x53, 0x06, 0x4b, 0x1f, 0x40, 0xc8, 0x3e, 0x17, 0x75, 0x0b, 0x1a, 0x95,
    0x2d, 0xbd, 0xb5, 0xa0, 0x09, 0xbd, 0x93, 0x44, 0x01, 0x0f, 0x17, 0x82, 0xac, 0x03, 0x7b, 0x2c,
    0x28, 0xb6, 0x30, 0x4f, 0x01, 0xdd, 0x49, 0x6c, 0x5d, 0xea, 0xef, 0xd6, 0xb1, 0x46, 0x03, 0x33,
    0x51, 0xd1, 0x7d, 0x51, 0xb5, 0x8a, 0x04, 0x32, 0x04, 0x15, 0x8b, 0xb1, 0x3e, 0xab, 0x30, 0xd9,
    0x2f, 0x5e, 0xa5, 0x2c, 0xcf, 0x47, 0x92, 0x45, 0x15, 0xda, 0x7a, 0xd7, 0xb3, 0xf3, 0xe9, 0x92,
    0x37, 0xcb, 0x46, 0x0d, 0xb5, 0x4d, 0x52, 0xf9, 0x64, 0x7e, 0xd4, 0xc7, 0x5d, 0x6f, 0xa0, 0x83,
    0x90, 0x7a, 0x78, 0x7d, 0x78, 0x69, 0x14, 0x29, 0xa6, 0x97, 0x6c, 0xfb, 0x06, 0xa4, 0xf9, 0xbb,
    0x9e, 0x0e, 0xa8, 0x7c, 0x77, 0xec, 0x97, 0x0f, 0x61, 0xab, 0xa2, 0xaf, 0xee, 0x73, 0x03, 0x20,
    0xb3, 0x10, 0xf3
};
#endif

PyTypeObject *init_Akonadi_SpecialCollectionAttribute(PyObject *enclosingClass)
{
    auto &typeStruct = SbkAkonadiCoreTypeStructs[SBK_Akonadi_SpecialCollectionAttribute_IDX];
    if (typeStruct.type != nullptr)
        return typeStruct.type;

    auto *base1 = reinterpret_cast<PyObject *>(Shiboken::Module::get(SbkAkonadiCoreTypeStructs[SBK_Akonadi_Attribute_IDX]));
    Shiboken::AutoDecRef Sbk_Akonadi_SpecialCollectionAttribute_Type_bases(PyTuple_Pack(1, base1));

    PyTypeObject *pyType = Shiboken::ObjectType::introduceWrapperType(
        enclosingClass,
        "SpecialCollectionAttribute",
        "Akonadi::SpecialCollectionAttribute*",
        &Sbk_Akonadi_SpecialCollectionAttribute_spec,
        &Shiboken::callCppDestructor< Akonadi::SpecialCollectionAttribute >,
        Sbk_Akonadi_SpecialCollectionAttribute_Type_bases.object(),
        Shiboken::ObjectType::WrapperFlags::InnerClass);
#if PYSIDE6_COMOPT_COMPRESS == 0
    InitSignatureStrings(pyType, Akonadi_SpecialCollectionAttribute_SignatureStrings);
#else
    InitSignatureBytes(pyType, Akonadi_SpecialCollectionAttribute_SignatureBytes, Akonadi_SpecialCollectionAttribute_SignatureByteSize);
#endif
    SbkObjectType_SetPropertyStrings(pyType, Sbk_Akonadi_SpecialCollectionAttribute_PropertyStrings);
    typeStruct.type = pyType;

    // Register Converter
    SbkConverter *converter = Shiboken::Conversions::createConverter(pyType,
        SpecialCollectionAttribute_PythonToCpp_SpecialCollectionAttribute_PTR,
        is_SpecialCollectionAttribute_PythonToCpp_SpecialCollectionAttribute_PTR_Convertible,
        SpecialCollectionAttribute_PTR_CppToPython_SpecialCollectionAttribute);

    Shiboken::Conversions::registerConverterName(converter, "Akonadi::SpecialCollectionAttribute");
    Shiboken::Conversions::registerConverterName(converter, "Akonadi::SpecialCollectionAttribute*");
    Shiboken::Conversions::registerConverterName(converter, "Akonadi::SpecialCollectionAttribute&");
    Shiboken::Conversions::registerConverterAlias(converter, "SpecialCollectionAttribute");
    Shiboken::Conversions::registerConverterAlias(converter, "SpecialCollectionAttribute*");
    Shiboken::Conversions::registerConverterAlias(converter, "SpecialCollectionAttribute&");
    Shiboken::Conversions::registerConverterName(converter, typeid(::Akonadi::SpecialCollectionAttribute).name());
    Shiboken::Conversions::registerConverterName(converter, typeid(SpecialCollectionAttributeWrapper).name());

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

    qRegisterMetaType< ::Akonadi::SpecialCollectionAttribute *>();

    return pyType;
}
