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

#include "sipAPIQtTextToSpeech.h"

#line 28 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qobject.sip"
#include <qobject.h>
#line 29 "/build/pyqt6/src/pyqt6-6.11.0/build/QtTextToSpeech/sipQtTextToSpeechcmodule.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qmetaobject.sip"
#include <qmetaobject.h>
#line 32 "/build/pyqt6/src/pyqt6-6.11.0/build/QtTextToSpeech/sipQtTextToSpeechcmodule.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 35 "/build/pyqt6/src/pyqt6-6.11.0/build/QtTextToSpeech/sipQtTextToSpeechcmodule.cpp"
#line 277 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 38 "/build/pyqt6/src/pyqt6-6.11.0/build/QtTextToSpeech/sipQtTextToSpeechcmodule.cpp"
#line 254 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 41 "/build/pyqt6/src/pyqt6-6.11.0/build/QtTextToSpeech/sipQtTextToSpeechcmodule.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qdatastream.sip"
#include <qdatastream.h>
#line 44 "/build/pyqt6/src/pyqt6-6.11.0/build/QtTextToSpeech/sipQtTextToSpeechcmodule.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtTextToSpeech/qvoice.sip"
#include <qvoice.h>
#line 47 "/build/pyqt6/src/pyqt6-6.11.0/build/QtTextToSpeech/sipQtTextToSpeechcmodule.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtTextToSpeech/qtexttospeech.sip"
#include <qtexttospeech.h>
#line 50 "/build/pyqt6/src/pyqt6-6.11.0/build/QtTextToSpeech/sipQtTextToSpeechcmodule.cpp"

/* Define the strings used by this module. */
const char sipStrings_QtTextToSpeech[] = {
    'Q', 'F', 'l', 'a', 'g', 's', '<', 'Q', 'T', 'e', 'x', 't', 'T', 'o', 'S', 'p', 'e', 'e', 'c', 'h', ':', ':', 'C', 'a', 'p', 'a', 'b', 'i', 'l', 'i', 't', 'y', '>', 0,
    'Q', 'T', 'e', 'x', 't', 'T', 'o', 'S', 'p', 'e', 'e', 'c', 'h', ':', ':', 'B', 'o', 'u', 'n', 'd', 'a', 'r', 'y', 'H', 'i', 'n', 't', 0,
    'Q', 'T', 'e', 'x', 't', 'T', 'o', 'S', 'p', 'e', 'e', 'c', 'h', ':', ':', 'E', 'r', 'r', 'o', 'r', 'R', 'e', 'a', 's', 'o', 'n', 0,
    'Q', 'T', 'e', 'x', 't', 'T', 'o', 'S', 'p', 'e', 'e', 'c', 'h', ':', ':', 'C', 'a', 'p', 'a', 'b', 'i', 'l', 'i', 't', 'y', 0,
    'P', 'y', 'Q', 't', '6', '.', 's', 'i', 'p', '.', 's', 'i', 'm', 'p', 'l', 'e', 'w', 'r', 'a', 'p', 'p', 'e', 'r', 0,
    'P', 'y', 'Q', 't', '6', '.', 'Q', 't', 'T', 'e', 'x', 't', 'T', 'o', 'S', 'p', 'e', 'e', 'c', 'h', 0,
    'Q', 'T', 'e', 'x', 't', 'T', 'o', 'S', 'p', 'e', 'e', 'c', 'h', ':', ':', 'S', 't', 'a', 't', 'e', 0,
    'W', 'o', 'r', 'd', 'B', 'y', 'W', 'o', 'r', 'd', 'P', 'r', 'o', 'g', 'r', 'e', 's', 's', 0,
    'e', 'n', 'g', 'i', 'n', 'e', 'C', 'a', 'p', 'a', 'b', 'i', 'l', 'i', 't', 'i', 'e', 's', 0,
    'a', 'b', 'o', 'u', 't', 'T', 'o', 'S', 'y', 'n', 't', 'h', 'e', 's', 'i', 'z', 'e', 0,
    'a', 'v', 'a', 'i', 'l', 'a', 'b', 'l', 'e', 'E', 'n', 'g', 'i', 'n', 'e', 's', 0,
    'a', 'v', 'a', 'i', 'l', 'a', 'b', 'l', 'e', 'L', 'o', 'c', 'a', 'l', 'e', 's', 0,
    'd', 'i', 's', 'c', 'o', 'n', 'n', 'e', 'c', 't', 'N', 'o', 't', 'i', 'f', 'y', 0,
    'a', 'v', 'a', 'i', 'l', 'a', 'b', 'l', 'e', 'V', 'o', 'i', 'c', 'e', 's', 0,
    'I', 'n', 'i', 't', 'i', 'a', 'l', 'i', 'z', 'a', 't', 'i', 'o', 'n', 0,
    'Q', 'V', 'o', 'i', 'c', 'e', ':', ':', 'G', 'e', 'n', 'd', 'e', 'r', 0,
    'C', 'o', 'n', 'f', 'i', 'g', 'u', 'r', 'a', 't', 'i', 'o', 'n', 0,
    'Q', 'L', 'i', 's', 't', '<', 'Q', 'V', 'o', 'i', 'c', 'e', '>', 0,
    'Q', 'T', 'e', 'x', 't', 'T', 'o', 'S', 'p', 'e', 'e', 'c', 'h', 0,
    'e', 'n', 'g', 'i', 'n', 'e', 'C', 'h', 'a', 'n', 'g', 'e', 'd', 0,
    'e', 'r', 'r', 'o', 'r', 'O', 'c', 'c', 'u', 'r', 'r', 'e', 'd', 0,
    'l', 'o', 'c', 'a', 'l', 'e', 'C', 'h', 'a', 'n', 'g', 'e', 'd', 0,
    'v', 'o', 'l', 'u', 'm', 'e', 'C', 'h', 'a', 'n', 'g', 'e', 'd', 0,
    'S', 'y', 'n', 't', 'h', 'e', 's', 'i', 'z', 'i', 'n', 'g', 0,
    'b', 'o', 'u', 'n', 'd', 'a', 'r', 'y', 'H', 'i', 'n', 't', 0,
    'p', 'i', 't', 'c', 'h', 'C', 'h', 'a', 'n', 'g', 'e', 'd', 0,
    's', 't', 'a', 't', 'e', 'C', 'h', 'a', 'n', 'g', 'e', 'd', 0,
    'v', 'o', 'i', 'c', 'e', 'C', 'h', 'a', 'n', 'g', 'e', 'd', 0,
    'P', 'a', 'u', 's', 'e', 'R', 'e', 's', 'u', 'm', 'e', 0,
    'Q', 'V', 'o', 'i', 'c', 'e', ':', ':', 'A', 'g', 'e', 0,
    'c', 'u', 's', 't', 'o', 'm', 'E', 'v', 'e', 'n', 't', 0,
    'e', 'r', 'r', 'o', 'r', 'R', 'e', 'a', 's', 'o', 'n', 0,
    'e', 'r', 'r', 'o', 'r', 'S', 't', 'r', 'i', 'n', 'g', 0,
    'e', 'v', 'e', 'n', 't', 'F', 'i', 'l', 't', 'e', 'r', 0,
    'r', 'a', 't', 'e', 'C', 'h', 'a', 'n', 'g', 'e', 'd', 0,
    '_', '_', 'l', 's', 'h', 'i', 'f', 't', '_', '_', 0,
    '_', '_', 'r', 's', 'h', 'i', 'f', 't', '_', '_', 0,
    'c', 'h', 'i', 'l', 'd', 'E', 'v', 'e', 'n', 't', 0,
    'g', 'e', 'n', 'd', 'e', 'r', 'N', 'a', 'm', 'e', 0,
    's', 'a', 'y', 'i', 'n', 'g', 'W', 'o', 'r', 'd', 0,
    't', 'i', 'm', 'e', 'r', 'E', 'v', 'e', 'n', 't', 0,
    'I', 'm', 'm', 'e', 'd', 'i', 'a', 't', 'e', 0,
    'U', 't', 't', 'e', 'r', 'a', 'n', 'c', 'e', 0,
    's', 'e', 't', 'E', 'n', 'g', 'i', 'n', 'e', 0,
    's', 'e', 't', 'L', 'o', 'c', 'a', 'l', 'e', 0,
    's', 'e', 't', 'V', 'o', 'l', 'u', 'm', 'e', 0,
    'P', 'l', 'a', 'y', 'b', 'a', 'c', 'k', 0,
    'S', 'e', 'n', 't', 'e', 'n', 'c', 'e', 0,
    'S', 'p', 'e', 'a', 'k', 'i', 'n', 'g', 0,
    'T', 'e', 'e', 'n', 'a', 'g', 'e', 'r', 0,
    'l', 'a', 'n', 'g', 'u', 'a', 'g', 'e', 0,
    's', 'e', 't', 'P', 'i', 't', 'c', 'h', 0,
    's', 'e', 't', 'V', 'o', 'i', 'c', 'e', 0,
    'D', 'e', 'f', 'a', 'u', 'l', 't', 0,
    'N', 'o', 'E', 'r', 'r', 'o', 'r', 0,
    'U', 'n', 'k', 'n', 'o', 'w', 'n', 0,
    'a', 'g', 'e', 'N', 'a', 'm', 'e', 0,
    'e', 'n', 'q', 'u', 'e', 'u', 'e', 0,
    's', 'e', 't', 'R', 'a', 't', 'e', 0,
    'F', 'e', 'm', 'a', 'l', 'e', 0,
    'P', 'a', 'u', 's', 'e', 'd', 0,
    'Q', 'V', 'o', 'i', 'c', 'e', 0,
    'S', 'e', 'n', 'i', 'o', 'r', 0,
    '_', '_', 'e', 'q', '_', '_', 0,
    '_', '_', 'n', 'e', '_', '_', 0,
    'e', 'n', 'g', 'i', 'n', 'e', 0,
    'g', 'e', 'n', 'd', 'e', 'r', 0,
    'l', 'o', 'c', 'a', 'l', 'e', 0,
    'p', 'a', 'r', 'a', 'm', 's', 0,
    'p', 'a', 'r', 'e', 'n', 't', 0,
    'r', 'e', 's', 'u', 'm', 'e', 0,
    'v', 'o', 'l', 'u', 'm', 'e', 0,
    'A', 'd', 'u', 'l', 't', 0,
    'C', 'h', 'i', 'l', 'd', 0,
    'I', 'n', 'p', 'u', 't', 0,
    'N', 'o', 'n', 'e', '_', 0,
    'O', 't', 'h', 'e', 'r', 0,
    'R', 'e', 'a', 'd', 'y', 0,
    'S', 'p', 'e', 'a', 'k', 0,
    'e', 'v', 'e', 'n', 't', 0,
    'p', 'a', 'u', 's', 'e', 0,
    'p', 'i', 't', 'c', 'h', 0,
    's', 't', 'a', 't', 'e', 0,
    'v', 'o', 'i', 'c', 'e', 0,
    'M', 'a', 'l', 'e', 0,
    'n', 'a', 'm', 'e', 0,
    'r', 'a', 't', 'e', 0,
    's', 't', 'o', 'p', 0,
    's', 'w', 'a', 'p', 0,
    's', 'a', 'y', 0,
};

bool sipVH_QtTextToSpeech_5(sip_gilstate_t sipGILState, sipVirtErrorHandlerFunc sipErrorHandler, sipSimpleWrapper *sipPySelf, PyObject *sipMethod, ::QEvent*a0)
{
    bool sipRes = 0;
    PyObject *sipResObj = sipCallMethod(SIP_NULLPTR, sipMethod, "D", a0, sipType_QEvent, SIP_NULLPTR);

    sipParseResultEx(sipGILState, sipErrorHandler, sipPySelf, sipMethod, sipResObj, "b", &sipRes);

    return sipRes;
}

bool sipVH_QtTextToSpeech_4(sip_gilstate_t sipGILState, sipVirtErrorHandlerFunc sipErrorHandler, sipSimpleWrapper *sipPySelf, PyObject *sipMethod, ::QObject*a0, ::QEvent*a1)
{
    bool sipRes = 0;
    PyObject *sipResObj = sipCallMethod(SIP_NULLPTR, sipMethod, "DD", a0, sipType_QObject, SIP_NULLPTR, a1, sipType_QEvent, SIP_NULLPTR);

    sipParseResultEx(sipGILState, sipErrorHandler, sipPySelf, sipMethod, sipResObj, "b", &sipRes);

    return sipRes;
}

void sipVH_QtTextToSpeech_3(sip_gilstate_t sipGILState, sipVirtErrorHandlerFunc sipErrorHandler, sipSimpleWrapper *sipPySelf, PyObject *sipMethod, ::QTimerEvent*a0)
{
    sipCallProcedureMethod(sipGILState, sipErrorHandler, sipPySelf, sipMethod, "D", a0, sipType_QTimerEvent, SIP_NULLPTR);
}

void sipVH_QtTextToSpeech_2(sip_gilstate_t sipGILState, sipVirtErrorHandlerFunc sipErrorHandler, sipSimpleWrapper *sipPySelf, PyObject *sipMethod, ::QChildEvent*a0)
{
    sipCallProcedureMethod(sipGILState, sipErrorHandler, sipPySelf, sipMethod, "D", a0, sipType_QChildEvent, SIP_NULLPTR);
}

void sipVH_QtTextToSpeech_1(sip_gilstate_t sipGILState, sipVirtErrorHandlerFunc sipErrorHandler, sipSimpleWrapper *sipPySelf, PyObject *sipMethod, ::QEvent*a0)
{
    sipCallProcedureMethod(sipGILState, sipErrorHandler, sipPySelf, sipMethod, "D", a0, sipType_QEvent, SIP_NULLPTR);
}

void sipVH_QtTextToSpeech_0(sip_gilstate_t sipGILState, sipVirtErrorHandlerFunc sipErrorHandler, sipSimpleWrapper *sipPySelf, PyObject *sipMethod, const ::QMetaMethod& a0)
{
    sipCallProcedureMethod(sipGILState, sipErrorHandler, sipPySelf, sipMethod, "N", new ::QMetaMethod(a0), sipType_QMetaMethod, SIP_NULLPTR);
}


extern "C" {static PyObject *slot___rshift__(PyObject *, PyObject *);}
static PyObject *slot___rshift__(PyObject *sipArg0, PyObject *sipArg1)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        ::QDataStream* a0;
        ::QVoice* a1;

        if (sipParsePair(&sipParseErr, sipArg0, sipArg1, "J9J9", sipType_QDataStream, &a0, sipType_QVoice, &a1))
        {
            ::QDataStream*sipRes;

            sipRes = &(*a0 >> *a1);

            return sipConvertFromType(sipRes, sipType_QDataStream, SIP_NULLPTR);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    PyErr_Clear();

    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
}


extern "C" {static PyObject *slot___lshift__(PyObject *, PyObject *);}
static PyObject *slot___lshift__(PyObject *sipArg0, PyObject *sipArg1)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        ::QDataStream* a0;
        const ::QVoice* a1;

        if (sipParsePair(&sipParseErr, sipArg0, sipArg1, "J9J9", sipType_QDataStream, &a0, sipType_QVoice, &a1))
        {
            ::QDataStream*sipRes;

            sipRes = &(*a0 << *a1);

            return sipConvertFromType(sipRes, sipType_QDataStream, SIP_NULLPTR);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    PyErr_Clear();

    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
}

static sipPySlotExtenderDef slotExtenders[] = {
    {(void *)slot___rshift__, rshift_slot, {0, 0, 0}},
    {(void *)slot___lshift__, lshift_slot, {0, 0, 0}},
    {SIP_NULLPTR, (sipPySlotType)0, {0, 0, 0}}
};


/* Convert to a sub-class if possible. */
extern "C" {static const sipTypeDef *sipSubClass_QTextToSpeech(void **);}
static const sipTypeDef *sipSubClass_QTextToSpeech(void **sipCppRet)
{
    ::QObject *sipCpp = reinterpret_cast< ::QObject *>(*sipCppRet);
    const sipTypeDef *sipType;

#line 30 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtTextToSpeech/qtexttospeech.sip"
    static struct class_graph {
        const char *name;
        sipTypeDef **type;
        int yes, no;
    } graph[] = {
        {sipName_QTextToSpeech, &sipType_QTextToSpeech, -1, -1},
    };
    
    int i = 0;
    
    sipType = NULL;
    
    do
    {
        struct class_graph *cg = &graph[i];
    
        if (cg->name != NULL && sipCpp->inherits(cg->name))
        {
            sipType = *cg->type;
            i = cg->yes;
        }
        else
            i = cg->no;
    }
    while (i >= 0);
#line 288 "/build/pyqt6/src/pyqt6-6.11.0/build/QtTextToSpeech/sipQtTextToSpeechcmodule.cpp"

    return sipType;
}
static sipEnumTypeDef enumTypes[] = {
    {{SIP_NULLPTR, SIP_TYPE_ENUM, sipNameNr_QTextToSpeech__BoundaryHint, SIP_NULLPTR, 0}, SIP_ENUM_ENUM, sipNameNr_BoundaryHint, 2, 5, SIP_NULLPTR},
    {{SIP_NULLPTR, SIP_TYPE_ENUM, sipNameNr_QTextToSpeech__Capability, SIP_NULLPTR, 0}, SIP_ENUM_ENUM, sipNameNr_Capability, 2, 5, SIP_NULLPTR},
    {{SIP_NULLPTR, SIP_TYPE_ENUM, sipNameNr_QTextToSpeech__ErrorReason, SIP_NULLPTR, 0}, SIP_ENUM_ENUM, sipNameNr_ErrorReason, 2, 5, SIP_NULLPTR},
    {{SIP_NULLPTR, SIP_TYPE_ENUM, sipNameNr_QTextToSpeech__State, SIP_NULLPTR, 0}, SIP_ENUM_ENUM, sipNameNr_State, 2, 5, SIP_NULLPTR},
    {{SIP_NULLPTR, SIP_TYPE_ENUM, sipNameNr_QVoice__Age, SIP_NULLPTR, 0}, SIP_ENUM_ENUM, sipNameNr_Age, 7, 5, SIP_NULLPTR},
    {{SIP_NULLPTR, SIP_TYPE_ENUM, sipNameNr_QVoice__Gender, SIP_NULLPTR, 0}, SIP_ENUM_ENUM, sipNameNr_Gender, 7, 3, SIP_NULLPTR},
};


/*
 * This defines each type in this module.
 */
sipTypeDef *sipExportedTypes_QtTextToSpeech[] = {
    &sipTypeDef_QtTextToSpeech_QFlags_0100QTextToSpeech_Capability.mtd_base,
    &sipTypeDef_QtTextToSpeech_QList_0100QVoice.mtd_base,
    &sipTypeDef_QtTextToSpeech_QTextToSpeech.ctd_base,
    &enumTypes[0].etd_base,
    &enumTypes[1].etd_base,
    &enumTypes[2].etd_base,
    &enumTypes[3].etd_base,
    &sipTypeDef_QtTextToSpeech_QVoice.ctd_base,
    &enumTypes[4].etd_base,
    &enumTypes[5].etd_base,
};


/*
 * These define each typedef in this module.
 */
static sipTypedefDef typedefsTable[] = {
    {"QTextToSpeech::Capabilities", "QFlags<QTextToSpeech::Capability>"},
};


/* This defines the types that this module needs to import from QtCore. */
sipImportedTypeDef sipImportedTypes_QtTextToSpeech_QtCore[] = {
    {"QChildEvent"},
    {"QDataStream"},
    {"QEvent"},
    {"QList<QLocale>"},
    {"QLocale"},
    {"QLocale::Language"},
    {"QMap<QString,QVariant>"},
    {"QMetaMethod"},
    {"QObject"},
    {"QString"},
    {"QStringList"},
    {"QTimerEvent"},
    {SIP_NULLPTR}
};


/*
 * This defines the virtual error handlers that this module needs to import
 * from QtCore.
 */
sipImportedVirtErrorHandlerDef sipImportedVirtErrorHandlers_QtTextToSpeech_QtCore[] = {
    {"PyQt6"},
    {SIP_NULLPTR}
};


/* This defines the modules that this module needs to import. */
static sipImportedModuleDef importsTable[] = {
    {"PyQt6.QtCore", sipImportedTypes_QtTextToSpeech_QtCore, sipImportedVirtErrorHandlers_QtTextToSpeech_QtCore, SIP_NULLPTR},
    {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR}
};


/* This defines the class sub-convertors that this module defines. */
static sipSubClassConvertorDef convertorsTable[] = {
    {sipSubClass_QTextToSpeech, {8, 0, 0}, SIP_NULLPTR},
    {SIP_NULLPTR, {0, 0, 0}, SIP_NULLPTR}
};


/* This defines this module. */
sipExportedModuleDef sipModuleAPI_QtTextToSpeech = {
    SIP_NULLPTR,
    8,
    sipNameNr_PyQt6_QtTextToSpeech,
    0,
    sipStrings_QtTextToSpeech,
    importsTable,
    10,
    sipExportedTypes_QtTextToSpeech,
    SIP_NULLPTR,
    1,
    typedefsTable,
    SIP_NULLPTR,
    convertorsTable,
    {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    SIP_NULLPTR,
    SIP_NULLPTR,
    slotExtenders,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
};


/* The SIP API and the APIs of any imported modules. */
const sipAPIDef *sipAPI_QtTextToSpeech;

sip_qt_metaobject_func sip_QtTextToSpeech_qt_metaobject;
sip_qt_metacall_func sip_QtTextToSpeech_qt_metacall;
sip_qt_metacast_func sip_QtTextToSpeech_qt_metacast;


/* The Python module initialisation function. */
#if defined(SIP_STATIC_MODULE)
extern "C" PyObject *PyInit_QtTextToSpeech()
#else
PyMODINIT_FUNC PyInit_QtTextToSpeech()
#endif
{
    static PyMethodDef sip_methods[] = {
        {SIP_NULLPTR, SIP_NULLPTR, 0, SIP_NULLPTR}
    };
    static PyModuleDef sip_module_def = {
        PyModuleDef_HEAD_INIT,
        "PyQt6.QtTextToSpeech",
        SIP_NULLPTR,
        -1,
        sip_methods,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_NULLPTR
    };

    PyObject *sipModule, *sipModuleDict;
    PyObject *sip_sipmod, *sip_capiobj;

    /* Initialise the module and get it's dictionary. */
    if ((sipModule = PyModule_Create(&sip_module_def)) == SIP_NULLPTR)
        return SIP_NULLPTR;

    sipModuleDict = PyModule_GetDict(sipModule);

    /* Get the SIP module's API. */
    if ((sip_sipmod = PyImport_ImportModule("PyQt6.sip")) == SIP_NULLPTR)
    {
        Py_DECREF(sipModule);
        return SIP_NULLPTR;
    }

    sip_capiobj = PyDict_GetItemString(PyModule_GetDict(sip_sipmod), "_C_API");
    Py_DECREF(sip_sipmod);

    if (sip_capiobj == SIP_NULLPTR || !PyCapsule_CheckExact(sip_capiobj))
    {
        PyErr_SetString(PyExc_AttributeError, "PyQt6.sip._C_API is missing or has the wrong type");
        Py_DECREF(sipModule);
        return SIP_NULLPTR;
    }

    sipAPI_QtTextToSpeech = reinterpret_cast<const sipAPIDef *>(PyCapsule_GetPointer(sip_capiobj, "PyQt6.sip._C_API"));

    if (sipAPI_QtTextToSpeech == SIP_NULLPTR)
    {
        Py_DECREF(sipModule);
        return SIP_NULLPTR;
    }

    /* Export the module and publish it's API. */
    if (sipExportModule(&sipModuleAPI_QtTextToSpeech, 13, 8, 0) < 0)
    {
        Py_DECREF(sipModule);
        return SIP_NULLPTR;
    }


    sip_QtTextToSpeech_qt_metaobject = (sip_qt_metaobject_func)sipImportSymbol("qtcore_qt_metaobject");
    sip_QtTextToSpeech_qt_metacall = (sip_qt_metacall_func)sipImportSymbol("qtcore_qt_metacall");
    sip_QtTextToSpeech_qt_metacast = (sip_qt_metacast_func)sipImportSymbol("qtcore_qt_metacast");

    if (!sip_QtTextToSpeech_qt_metacast)
        Py_FatalError("Unable to import qtcore_qt_metacast");

    /* Initialise the module now all its dependencies have been set up. */
    if (sipInitModule(&sipModuleAPI_QtTextToSpeech, sipModuleDict) < 0)
    {
        Py_DECREF(sipModule);
        return SIP_NULLPTR;
    }
    qMetaTypeId<::QVoice::Age>();
    qMetaTypeId<::QVoice::Gender>();
    qMetaTypeId<::QTextToSpeech::Capability>();
    qMetaTypeId<::QTextToSpeech::State>();
    qMetaTypeId<::QTextToSpeech::ErrorReason>();
    qMetaTypeId<::QTextToSpeech::BoundaryHint>();
    qMetaTypeId<QFlags< ::QTextToSpeech::Capability>>();

    return sipModule;
}
