/****************************************************************************
**
** Copyright (C) 2016 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of Qt for Python.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and The Qt Company. For licensing terms
** and conditions see https://www.qt.io/terms-conditions. For further
** information use the contact form at https://www.qt.io/contact-us.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 3 as published by the Free Software
** Foundation and appearing in the file LICENSE.LGPL3 included in the
** packaging of this file. Please review the following information to
** ensure the GNU Lesser General Public License version 3 requirements
** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
**
** GNU General Public License Usage
** Alternatively, this file may be used under the terms of the GNU
** General Public License version 2.0 or (at your option) the GNU General
** Public license version 3 or any later version approved by the KDE Free
** Qt Foundation. The licenses are as published by the Free Software
** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
** included in the packaging of this file. Please review the following
** information to ensure the GNU General Public License requirements will
** be met: https://www.gnu.org/licenses/gpl-2.0.html and
** https://www.gnu.org/licenses/gpl-3.0.html.
**
** $QT_END_LICENSE$
**
****************************************************************************/

//workaround to access protected functions
#define protected public

// default includes
#include <shiboken.h>
#ifndef QT_NO_VERSION_TAGGING
#  define QT_NO_VERSION_TAGGING
#endif
#include <QDebug>
#include <pysidesignal.h>
#include <pysideproperty.h>
#include <pyside.h>
#include <pysideqenum.h>
#include <feature_select.h>
QT_WARNING_DISABLE_DEPRECATED

#include <typeinfo>
#include <signalmanager.h>
#include <pysidemetafunction.h>
#include <algorithm>
#include <set>
#include <iterator>

// module include
#include "pyside6_qtnetwork_python.h"

// main header
#include "qsslsocket_wrapper.h"

// inner classes

#include <cctype>
#include <cstring>



template <class T>
static const char *typeNameOf(const T &t)
{
    const char *typeName =  typeid(t).name();
    auto size = std::strlen(typeName);
#if defined(Q_CC_MSVC) // MSVC: "class QPaintDevice * __ptr64"
    if (auto lastStar = strchr(typeName, '*')) {
        // MSVC: "class QPaintDevice * __ptr64"
        while (*--lastStar == ' ') {
        }
        size = lastStar - typeName + 1;
    }
#else // g++, Clang: "QPaintDevice *" -> "P12QPaintDevice"
    if (size > 2 && typeName[0] == 'P' && std::isdigit(typeName[1])) {
        ++typeName;
        --size;
    }
#endif
    char *result = new char[size + 1];
    result[size] = '\0';
    memcpy(result, typeName, size);
    return result;
}

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

void QSslSocketWrapper::resetPyMethodCache()
{
    std::fill_n(m_PyMethodCache, sizeof(m_PyMethodCache) / sizeof(m_PyMethodCache[0]), false);
}

QSslSocketWrapper::QSslSocketWrapper(QObject * parent) : QSslSocket(parent)
{
    resetPyMethodCache();
    // ... middle
}

bool QSslSocketWrapper::atEnd() const
{
    if (m_PyMethodCache[0])
        return this->::QSslSocket::atEnd();
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "atEnd";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[0] = true;
        return this->::QSslSocket::atEnd();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.atEnd",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QSslSocketWrapper::bytesAvailable() const
{
    if (m_PyMethodCache[1])
        return this->::QSslSocket::bytesAvailable();
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return 0;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "bytesAvailable";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[1] = true;
        return this->::QSslSocket::bytesAvailable();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return 0;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.bytesAvailable",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QSslSocketWrapper::bytesToWrite() const
{
    if (m_PyMethodCache[2])
        return this->::QSslSocket::bytesToWrite();
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return 0;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "bytesToWrite";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[2] = true;
        return this->::QSslSocket::bytesToWrite();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return 0;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.bytesToWrite",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QSslSocketWrapper::canReadLine() const
{
    if (m_PyMethodCache[3])
        return this->::QSslSocket::canReadLine();
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "canReadLine";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[3] = true;
        return this->::QSslSocket::canReadLine();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.canReadLine",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

void QSslSocketWrapper::childEvent(QChildEvent * event)
{
    if (m_PyMethodCache[4]) {
        return this->::QObject::childEvent(event);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "childEvent";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[4] = true;
        return this->::QObject::childEvent(event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QCHILDEVENT_IDX], event)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void QSslSocketWrapper::close()
{
    if (m_PyMethodCache[5]) {
        return this->::QSslSocket::close();
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "close";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[5] = true;
        return this->::QSslSocket::close();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void QSslSocketWrapper::connectNotify(const QMetaMethod & signal)
{
    if (m_PyMethodCache[6]) {
        return this->::QObject::connectNotify(signal);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "connectNotify";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[6] = true;
        return this->::QObject::connectNotify(signal);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QMETAMETHOD_IDX], &signal)
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void QSslSocketWrapper::connectToHost(const QString & hostName, quint16 port, QFlags<QIODeviceBase::OpenModeFlag> openMode, QAbstractSocket::NetworkLayerProtocol protocol)
{
    if (m_PyMethodCache[7]) {
        return this->::QSslSocket::connectToHost(hostName, port, openMode, protocol);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "connectToHost";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[7] = true;
        return this->::QSslSocket::connectToHost(hostName, port, openMode, protocol);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(NHNN)",
        Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], &hostName),
        port,
        Shiboken::Conversions::copyToPython(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, &openMode),
        Shiboken::Conversions::copyToPython(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_NETWORKLAYERPROTOCOL_IDX]))->converter, &protocol)
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void QSslSocketWrapper::customEvent(QEvent * event)
{
    if (m_PyMethodCache[8]) {
        return this->::QObject::customEvent(event);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "customEvent";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[8] = true;
        return this->::QObject::customEvent(event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QEVENT_IDX], event)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void QSslSocketWrapper::disconnectFromHost()
{
    if (m_PyMethodCache[9]) {
        return this->::QSslSocket::disconnectFromHost();
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "disconnectFromHost";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[9] = true;
        return this->::QSslSocket::disconnectFromHost();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void QSslSocketWrapper::disconnectNotify(const QMetaMethod & signal)
{
    if (m_PyMethodCache[10]) {
        return this->::QObject::disconnectNotify(signal);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "disconnectNotify";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[10] = true;
        return this->::QObject::disconnectNotify(signal);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QMETAMETHOD_IDX], &signal)
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

bool QSslSocketWrapper::event(QEvent * event)
{
    if (m_PyMethodCache[11])
        return this->::QObject::event(event);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "event";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[11] = true;
        return this->::QObject::event(event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QEVENT_IDX], event)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.event",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QSslSocketWrapper::eventFilter(QObject * watched, QEvent * event)
{
    if (m_PyMethodCache[12])
        return this->::QObject::eventFilter(watched, event);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "eventFilter";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[12] = true;
        return this->::QObject::eventFilter(watched, event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(NN)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], watched),
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QEVENT_IDX], event)
    ));
    bool invalidateArg2 = PyTuple_GET_ITEM(pyArgs, 1)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg2)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 1));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.eventFilter",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QSslSocketWrapper::isSequential() const
{
    if (m_PyMethodCache[13])
        return this->::QAbstractSocket::isSequential();
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "isSequential";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[13] = true;
        return this->::QAbstractSocket::isSequential();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.isSequential",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QSslSocketWrapper::open(QFlags<QIODeviceBase::OpenModeFlag> mode)
{
    if (m_PyMethodCache[15])
        return this->::QIODevice::open(mode);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "open";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[15] = true;
        return this->::QIODevice::open(mode);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::copyToPython(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, &mode)
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.open",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QSslSocketWrapper::pos() const
{
    if (m_PyMethodCache[16])
        return this->::QIODevice::pos();
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return 0;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "pos";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[16] = true;
        return this->::QIODevice::pos();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return 0;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.pos",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QSslSocketWrapper::readData(char * data, qint64 maxlen)
{
    if (m_PyMethodCache[17]) {
        return this->::QSslSocket::readData(data, maxlen);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return 0;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "readData";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[17] = true;
        return this->::QSslSocket::readData(data, maxlen);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(L)",
        maxlen
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return 0;
    }

    // Begin code injection
    // ========================================================================
    // START of custom code block [file: ../glue/qtcore.cpp (return-readData)]
    qint64 cppResult = 0;
    if (PyBytes_Check(pyResult.object())) {
        cppResult = PyBytes_GET_SIZE(pyResult.object());
        memcpy(data, PyBytes_AS_STRING(pyResult.object()), cppResult);
    } else if (Shiboken::String::check(pyResult.object())) {
        cppResult = Shiboken::String::len(pyResult.object());
        memcpy(data, Shiboken::String::toCString(pyResult.object()), cppResult);
    }
    // END of custom code block [file: ../glue/qtcore.cpp (return-readData)]
    // ========================================================================
    // End of code injection

    return cppResult;
}

qint64 QSslSocketWrapper::readLineData(char * data, qint64 maxlen)
{
    if (m_PyMethodCache[18]) {
        return this->::QAbstractSocket::readLineData(data, maxlen);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return 0;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "readLineData";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[18] = true;
        return this->::QAbstractSocket::readLineData(data, maxlen);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(L)",
        maxlen
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return 0;
    }

    // Begin code injection
    // ========================================================================
    // START of custom code block [file: ../glue/qtcore.cpp (return-readData)]
    qint64 cppResult = 0;
    if (PyBytes_Check(pyResult.object())) {
        cppResult = PyBytes_GET_SIZE(pyResult.object());
        memcpy(data, PyBytes_AS_STRING(pyResult.object()), cppResult);
    } else if (Shiboken::String::check(pyResult.object())) {
        cppResult = Shiboken::String::len(pyResult.object());
        memcpy(data, Shiboken::String::toCString(pyResult.object()), cppResult);
    }
    // END of custom code block [file: ../glue/qtcore.cpp (return-readData)]
    // ========================================================================
    // End of code injection

    return cppResult;
}

bool QSslSocketWrapper::reset()
{
    if (m_PyMethodCache[19])
        return this->::QIODevice::reset();
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "reset";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[19] = true;
        return this->::QIODevice::reset();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.reset",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

void QSslSocketWrapper::resume()
{
    if (m_PyMethodCache[20]) {
        return this->::QSslSocket::resume();
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "resume";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[20] = true;
        return this->::QSslSocket::resume();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

bool QSslSocketWrapper::seek(qint64 pos)
{
    if (m_PyMethodCache[21])
        return this->::QIODevice::seek(pos);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "seek";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[21] = true;
        return this->::QIODevice::seek(pos);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(L)",
        pos
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.seek",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

void QSslSocketWrapper::setReadBufferSize(qint64 size)
{
    if (m_PyMethodCache[22]) {
        return this->::QSslSocket::setReadBufferSize(size);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "setReadBufferSize";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[22] = true;
        return this->::QSslSocket::setReadBufferSize(size);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(L)",
        size
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

bool QSslSocketWrapper::setSocketDescriptor(qintptr socketDescriptor, QAbstractSocket::SocketState state, QFlags<QIODeviceBase::OpenModeFlag> openMode)
{
    if (m_PyMethodCache[23])
        return this->::QSslSocket::setSocketDescriptor(socketDescriptor, state, openMode);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "setSocketDescriptor";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[23] = true;
        return this->::QSslSocket::setSocketDescriptor(socketDescriptor, state, openMode);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(NNN)",
        Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QINTPTR_IDX], &socketDescriptor),
        Shiboken::Conversions::copyToPython(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_SOCKETSTATE_IDX]))->converter, &state),
        Shiboken::Conversions::copyToPython(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, &openMode)
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.setSocketDescriptor",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

void QSslSocketWrapper::setSocketOption(QAbstractSocket::SocketOption option, const QVariant & value)
{
    if (m_PyMethodCache[24]) {
        return this->::QSslSocket::setSocketOption(option, value);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "setSocketOption";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[24] = true;
        return this->::QSslSocket::setSocketOption(option, value);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(NN)",
        Shiboken::Conversions::copyToPython(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_SOCKETOPTION_IDX]))->converter, &option),
        Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QVARIANT_IDX], &value)
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

qint64 QSslSocketWrapper::size() const
{
    if (m_PyMethodCache[25])
        return this->::QIODevice::size();
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return 0;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "size";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[25] = true;
        return this->::QIODevice::size();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return 0;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.size",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QSslSocketWrapper::skipData(qint64 maxSize)
{
    if (m_PyMethodCache[26])
        return this->::QSslSocket::skipData(maxSize);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return 0;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "skipData";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[26] = true;
        return this->::QSslSocket::skipData(maxSize);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(L)",
        maxSize
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return 0;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.skipData",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qintptr QSslSocketWrapper::socketDescriptor() const
{
    if (m_PyMethodCache[27])
        return this->::QAbstractSocket::socketDescriptor();
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return ::qintptr();
    static PyObject *nameCache[2] = {};
    static const char *funcName = "socketDescriptor";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[27] = true;
        return this->::QAbstractSocket::socketDescriptor();
    }

    Shiboken::AutoDecRef pyArgs(PyTuple_New(0));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return ::qintptr();
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QINTPTR_IDX], pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.socketDescriptor",
            "qintptr",
            Py_TYPE(pyResult)->tp_name);
        return ::qintptr();
    }
    ::qintptr cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

QVariant QSslSocketWrapper::socketOption(QAbstractSocket::SocketOption option)
{
    if (m_PyMethodCache[28])
        return this->::QSslSocket::socketOption(option);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return ::QVariant();
    static PyObject *nameCache[2] = {};
    static const char *funcName = "socketOption";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[28] = true;
        return this->::QSslSocket::socketOption(option);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::copyToPython(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_SOCKETOPTION_IDX]))->converter, &option)
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return ::QVariant();
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QVARIANT_IDX], pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.socketOption",
            "QVariant",
            Py_TYPE(pyResult)->tp_name);
        return ::QVariant();
    }
    ::QVariant cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

void QSslSocketWrapper::timerEvent(QTimerEvent * event)
{
    if (m_PyMethodCache[29]) {
        return this->::QObject::timerEvent(event);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "timerEvent";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[29] = true;
        return this->::QObject::timerEvent(event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QTIMEREVENT_IDX], event)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

bool QSslSocketWrapper::waitForBytesWritten(int msecs)
{
    if (m_PyMethodCache[30])
        return this->::QSslSocket::waitForBytesWritten(msecs);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "waitForBytesWritten";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[30] = true;
        return this->::QSslSocket::waitForBytesWritten(msecs);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(i)",
        msecs
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.waitForBytesWritten",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QSslSocketWrapper::waitForConnected(int msecs)
{
    if (m_PyMethodCache[31])
        return this->::QSslSocket::waitForConnected(msecs);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "waitForConnected";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[31] = true;
        return this->::QSslSocket::waitForConnected(msecs);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(i)",
        msecs
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.waitForConnected",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QSslSocketWrapper::waitForDisconnected(int msecs)
{
    if (m_PyMethodCache[32])
        return this->::QSslSocket::waitForDisconnected(msecs);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "waitForDisconnected";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[32] = true;
        return this->::QSslSocket::waitForDisconnected(msecs);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(i)",
        msecs
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.waitForDisconnected",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QSslSocketWrapper::waitForReadyRead(int msecs)
{
    if (m_PyMethodCache[33])
        return this->::QSslSocket::waitForReadyRead(msecs);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "waitForReadyRead";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[33] = true;
        return this->::QSslSocket::waitForReadyRead(msecs);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(i)",
        msecs
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.waitForReadyRead",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QSslSocketWrapper::writeData(const char * data, qint64 len)
{
    if (m_PyMethodCache[34])
        return this->::QSslSocket::writeData(data, len);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return 0;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "writeData";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[34] = true;
        return this->::QSslSocket::writeData(data, len);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(NL)",
        Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<const char *>(), data),
        len
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return 0;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QSslSocket.writeData",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

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

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

void *QSslSocketWrapper::qt_metacast(const char *_clname)
{
    if (!_clname)
        return {};
    SbkObject *pySelf = Shiboken::BindingManager::instance().retrieveWrapper(this);
    if (pySelf && PySide::inherits(Py_TYPE(pySelf), _clname))
        return static_cast<void *>(const_cast< QSslSocketWrapper *>(this));
    return QSslSocket::qt_metacast(_clname);
}

QSslSocketWrapper::~QSslSocketWrapper()
{
    SbkObject *wrapper = Shiboken::BindingManager::instance().retrieveWrapper(this);
    Shiboken::Object::destroy(wrapper, this);
}

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

extern "C" {
static int
Sbk_QSslSocket_Init(PyObject *self, PyObject *args, PyObject *kwds)
{
    const QMetaObject *metaObject;
    SbkObject *sbkSelf = reinterpret_cast<SbkObject *>(self);
    PySide::Feature::Select(self);
    if (Shiboken::Object::isUserType(self) && !Shiboken::ObjectType::canCallConstructor(self->ob_type, Shiboken::SbkType< ::QSslSocket >()))
        return -1;

    ::QSslSocketWrapper *cptr{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.__init__";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths


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


    // Overloaded function decisor
    // 0: QSslSocket::QSslSocket(QObject*)
    if (numArgs == 0) {
        overloadId = 0; // QSslSocket(QObject*)
    } else if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], (pyArgs[0])))) {
        overloadId = 0; // QSslSocket(QObject*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocket_Init_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_parent = Shiboken::String::createStaticString("parent");
            if (PyDict_Contains(kwds, key_parent)) {
                value = PyDict_GetItem(kwds, key_parent);
                if (value && pyArgs[0]) {
                    errInfo.reset(key_parent);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocket_Init_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], (pyArgs[0]))))
                        goto Sbk_QSslSocket_Init_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_parent);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                // fall through to handle extra keyword signals and properties
            }
        }
        if (!Shiboken::Object::isValid(pyArgs[0]))
            return -1;
        ::QObject *cppArg0 = nullptr;
        if (pythonToCpp[0])
            pythonToCpp[0](pyArgs[0], &cppArg0);

        if (!PyErr_Occurred()) {
            // QSslSocket(QObject*)
            void *addr = PySide::nextQObjectMemoryAddr();
            if (addr) {
                cptr = new (addr) ::QSslSocketWrapper(cppArg0);
                PySide::setNextQObjectMemoryAddr(0);
            } else {
                cptr = new ::QSslSocketWrapper(cppArg0);
            }

            Shiboken::Object::setParent(pyArgs[0], self);
        }
    }

    if (PyErr_Occurred() || !Shiboken::Object::setCppPointer(sbkSelf, Shiboken::SbkType< ::QSslSocket >(), cptr)) {
        delete cptr;
        return -1;
    }
    if (!cptr) goto Sbk_QSslSocket_Init_TypeError;

    Shiboken::Object::setValidCpp(sbkSelf, true);
    Shiboken::Object::setHasCppWrapper(sbkSelf, true);
    if (Shiboken::BindingManager::instance().hasWrapper(cptr)) {
        Shiboken::BindingManager::instance().releaseWrapper(Shiboken::BindingManager::instance().retrieveWrapper(cptr));
    }
    Shiboken::BindingManager::instance().registerWrapper(sbkSelf, cptr);

    // QObject setup
    PySide::Signal::updateSourceObject(self);
    metaObject = cptr->metaObject(); // <- init python qt properties
    if (!errInfo.isNull() && PyDict_Check(errInfo.object())) {
        if (!PySide::fillQtProperties(self, metaObject, errInfo))
            goto Sbk_QSslSocket_Init_TypeError;
    };


    return 1;

    Sbk_QSslSocket_Init_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return -1;
}

static PyObject *Sbk_QSslSocketFunc_activeBackend(PyObject *self)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.activeBackend";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // activeBackend()
            QString cppResult = ::QSslSocket::activeBackend();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_atEnd(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.atEnd";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // atEnd()const
            bool cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? const_cast<const ::QSslSocket *>(cppSelf)->::QSslSocket::atEnd()
                : const_cast<const ::QSslSocket *>(cppSelf)->atEnd();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_availableBackends(PyObject *self)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.availableBackends";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // availableBackends()
            QList<QString > cppResult = ::QSslSocket::availableBackends();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QSTRING_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_bytesAvailable(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.bytesAvailable";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // bytesAvailable()const
            qint64 cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? const_cast<const ::QSslSocket *>(cppSelf)->::QSslSocket::bytesAvailable()
                : const_cast<const ::QSslSocket *>(cppSelf)->bytesAvailable();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_bytesToWrite(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.bytesToWrite";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // bytesToWrite()const
            qint64 cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? const_cast<const ::QSslSocket *>(cppSelf)->::QSslSocket::bytesToWrite()
                : const_cast<const ::QSslSocket *>(cppSelf)->bytesToWrite();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_canReadLine(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.canReadLine";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // canReadLine()const
            bool cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? const_cast<const ::QSslSocket *>(cppSelf)->::QSslSocket::canReadLine()
                : const_cast<const ::QSslSocket *>(cppSelf)->canReadLine();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_close(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.close";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // close()
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::close()
                : cppSelf->close();
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;
}

static PyObject *Sbk_QSslSocketFunc_connectToHost(PyObject *self, PyObject *args, PyObject *kwds)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.connectToHost";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[4];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0, 0, 0};

    // invalid argument lengths
    if (numArgs > 4) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_connectToHost_TypeError;
    } else if (numArgs < 2) {
        static PyObject *const too_few = Shiboken::String::createStaticString("<");
        errInfo.reset(too_few);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_connectToHost_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|OOOO:connectToHost", &(pyArgs[0]), &(pyArgs[1]), &(pyArgs[2]), &(pyArgs[3])))
        return {};


    // Overloaded function decisor
    // 0: QAbstractSocket::connectToHost(QString,quint16,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
    // 1: QAbstractSocket::connectToHost(QHostAddress,quint16,QFlags<QIODeviceBase::OpenModeFlag>)
    if (numArgs >= 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtNetworkTypes[SBK_QHOSTADDRESS_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<quint16>(), (pyArgs[1])))) {
        if (numArgs == 2) {
            overloadId = 1; // connectToHost(QHostAddress,quint16,QFlags<QIODeviceBase::OpenModeFlag>)
        } else if (numArgs >= 3
            && (pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, (pyArgs[2])))) {
            overloadId = 1; // connectToHost(QHostAddress,quint16,QFlags<QIODeviceBase::OpenModeFlag>)
        }
    } else if (numArgs >= 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<quint16>(), (pyArgs[1])))) {
        if (numArgs == 2) {
            overloadId = 0; // connectToHost(QString,quint16,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
        } else if (numArgs >= 3
            && (pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, (pyArgs[2])))) {
            if (numArgs == 3) {
                overloadId = 0; // connectToHost(QString,quint16,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
            } else if (numArgs >= 4
                && (pythonToCpp[3] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_NETWORKLAYERPROTOCOL_IDX]))->converter, (pyArgs[3])))) {
                overloadId = 0; // connectToHost(QString,quint16,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
            }
        }
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_connectToHost_TypeError;

    // Call function/method
    switch (overloadId) {
        case 0: // connectToHost(const QString & hostName, quint16 port, QFlags<QIODeviceBase::OpenModeFlag> openMode, QAbstractSocket::NetworkLayerProtocol protocol)
        {
            if (kwds && PyDict_Size(kwds) > 0) {
                PyObject *value{};
                Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
                static PyObject *const key_openMode = Shiboken::String::createStaticString("openMode");
                if (PyDict_Contains(kwds, key_openMode)) {
                    value = PyDict_GetItem(kwds, key_openMode);
                    if (value && pyArgs[2]) {
                        errInfo.reset(key_openMode);
                        Py_INCREF(errInfo.object());
                        goto Sbk_QSslSocketFunc_connectToHost_TypeError;
                    }
                    if (value) {
                        pyArgs[2] = value;
                        if (!(pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, (pyArgs[2]))))
                            goto Sbk_QSslSocketFunc_connectToHost_TypeError;
                    }
                    PyDict_DelItem(kwds_dup, key_openMode);
                }
                static PyObject *const key_protocol = Shiboken::String::createStaticString("protocol");
                if (PyDict_Contains(kwds, key_protocol)) {
                    value = PyDict_GetItem(kwds, key_protocol);
                    if (value && pyArgs[3]) {
                        errInfo.reset(key_protocol);
                        Py_INCREF(errInfo.object());
                        goto Sbk_QSslSocketFunc_connectToHost_TypeError;
                    }
                    if (value) {
                        pyArgs[3] = value;
                        if (!(pythonToCpp[3] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_NETWORKLAYERPROTOCOL_IDX]))->converter, (pyArgs[3]))))
                            goto Sbk_QSslSocketFunc_connectToHost_TypeError;
                    }
                    PyDict_DelItem(kwds_dup, key_protocol);
                }
                if (PyDict_Size(kwds_dup) > 0) {
                    errInfo.reset(kwds_dup.release());
                    goto Sbk_QSslSocketFunc_connectToHost_TypeError;
                }
            }
            ::QString cppArg0;
            pythonToCpp[0](pyArgs[0], &cppArg0);
            quint16 cppArg1;
            pythonToCpp[1](pyArgs[1], &cppArg1);
            ::QFlags<QIODeviceBase::OpenModeFlag> cppArg2(QIODeviceBase::OpenModeFlag::ReadWrite);
            if (pythonToCpp[2])
                pythonToCpp[2](pyArgs[2], &cppArg2);
            ::QAbstractSocket::NetworkLayerProtocol cppArg3(QAbstractSocket::NetworkLayerProtocol::AnyIPProtocol);
            if (pythonToCpp[3])
                pythonToCpp[3](pyArgs[3], &cppArg3);

            if (!PyErr_Occurred()) {
                // connectToHost(QString,quint16,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
                Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                    ? cppSelf->::QSslSocket::connectToHost(cppArg0, cppArg1, cppArg2, cppArg3)
                    : cppSelf->connectToHost(cppArg0, cppArg1, cppArg2, cppArg3);
            }
            break;
        }
        case 1: // connectToHost(const QHostAddress & address, quint16 port, QFlags<QIODeviceBase::OpenModeFlag> mode)
        {
            if (kwds && PyDict_Size(kwds) > 0) {
                PyObject *value{};
                Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
                static PyObject *const key_mode = Shiboken::String::createStaticString("mode");
                if (PyDict_Contains(kwds, key_mode)) {
                    value = PyDict_GetItem(kwds, key_mode);
                    if (value && pyArgs[2]) {
                        errInfo.reset(key_mode);
                        Py_INCREF(errInfo.object());
                        goto Sbk_QSslSocketFunc_connectToHost_TypeError;
                    }
                    if (value) {
                        pyArgs[2] = value;
                        if (!(pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, (pyArgs[2]))))
                            goto Sbk_QSslSocketFunc_connectToHost_TypeError;
                    }
                    PyDict_DelItem(kwds_dup, key_mode);
                }
                if (PyDict_Size(kwds_dup) > 0) {
                    errInfo.reset(kwds_dup.release());
                    goto Sbk_QSslSocketFunc_connectToHost_TypeError;
                }
            }
            if (!Shiboken::Object::isValid(pyArgs[0]))
                return {};
            ::QHostAddress cppArg0_local;
            ::QHostAddress *cppArg0 = &cppArg0_local;
            if (pythonToCpp[0].isValue())
                pythonToCpp[0](pyArgs[0], &cppArg0_local);
            else
                pythonToCpp[0](pyArgs[0], &cppArg0);

            quint16 cppArg1;
            pythonToCpp[1](pyArgs[1], &cppArg1);
            ::QFlags<QIODeviceBase::OpenModeFlag> cppArg2(QIODeviceBase::OpenModeFlag::ReadWrite);
            if (pythonToCpp[2])
                pythonToCpp[2](pyArgs[2], &cppArg2);

            if (!PyErr_Occurred()) {
                // connectToHost(QHostAddress,quint16,QFlags<QIODeviceBase::OpenModeFlag>)
                PyThreadState *_save = PyEval_SaveThread(); // Py_BEGIN_ALLOW_THREADS
                reinterpret_cast<QTcpSocket *>(cppSelf)->connectToHost(*cppArg0, cppArg1, cppArg2);
                PyEval_RestoreThread(_save); // Py_END_ALLOW_THREADS
            }
            break;
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_connectToHost_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_connectToHostEncrypted(PyObject *self, PyObject *args, PyObject *kwds)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.connectToHostEncrypted";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[5];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0, 0, 0, 0};

    // invalid argument lengths
    if (numArgs > 5) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
    } else if (numArgs < 2) {
        static PyObject *const too_few = Shiboken::String::createStaticString("<");
        errInfo.reset(too_few);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|OOOOO:connectToHostEncrypted", &(pyArgs[0]), &(pyArgs[1]), &(pyArgs[2]), &(pyArgs[3]), &(pyArgs[4])))
        return {};


    // Overloaded function decisor
    // 0: QSslSocket::connectToHostEncrypted(QString,quint16,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
    // 1: QSslSocket::connectToHostEncrypted(QString,quint16,QString,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
    if (numArgs >= 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<quint16>(), (pyArgs[1])))) {
        if (numArgs == 2) {
            overloadId = 0; // connectToHostEncrypted(QString,quint16,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
        } else if (numArgs >= 3
            && (pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[2])))) {
            if (numArgs == 3) {
                overloadId = 1; // connectToHostEncrypted(QString,quint16,QString,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
            } else if (numArgs >= 4
                && (pythonToCpp[3] = Shiboken::Conversions::pythonToCppConversion(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, (pyArgs[3])))) {
                if (numArgs == 4) {
                    overloadId = 1; // connectToHostEncrypted(QString,quint16,QString,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
                } else if (numArgs >= 5
                    && (pythonToCpp[4] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_NETWORKLAYERPROTOCOL_IDX]))->converter, (pyArgs[4])))) {
                    overloadId = 1; // connectToHostEncrypted(QString,quint16,QString,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
                }
            }
        } else if (numArgs >= 3
            && (pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, (pyArgs[2])))) {
            if (numArgs == 3) {
                overloadId = 0; // connectToHostEncrypted(QString,quint16,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
            } else if (numArgs >= 4
                && (pythonToCpp[3] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_NETWORKLAYERPROTOCOL_IDX]))->converter, (pyArgs[3])))) {
                overloadId = 0; // connectToHostEncrypted(QString,quint16,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
            }
        }
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;

    // Call function/method
    switch (overloadId) {
        case 0: // connectToHostEncrypted(const QString & hostName, quint16 port, QFlags<QIODeviceBase::OpenModeFlag> mode, QAbstractSocket::NetworkLayerProtocol protocol)
        {
            if (kwds && PyDict_Size(kwds) > 0) {
                PyObject *value{};
                Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
                static PyObject *const key_mode = Shiboken::String::createStaticString("mode");
                if (PyDict_Contains(kwds, key_mode)) {
                    value = PyDict_GetItem(kwds, key_mode);
                    if (value && pyArgs[2]) {
                        errInfo.reset(key_mode);
                        Py_INCREF(errInfo.object());
                        goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
                    }
                    if (value) {
                        pyArgs[2] = value;
                        if (!(pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, (pyArgs[2]))))
                            goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
                    }
                    PyDict_DelItem(kwds_dup, key_mode);
                }
                static PyObject *const key_protocol = Shiboken::String::createStaticString("protocol");
                if (PyDict_Contains(kwds, key_protocol)) {
                    value = PyDict_GetItem(kwds, key_protocol);
                    if (value && pyArgs[3]) {
                        errInfo.reset(key_protocol);
                        Py_INCREF(errInfo.object());
                        goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
                    }
                    if (value) {
                        pyArgs[3] = value;
                        if (!(pythonToCpp[3] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_NETWORKLAYERPROTOCOL_IDX]))->converter, (pyArgs[3]))))
                            goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
                    }
                    PyDict_DelItem(kwds_dup, key_protocol);
                }
                if (PyDict_Size(kwds_dup) > 0) {
                    errInfo.reset(kwds_dup.release());
                    goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
                }
            }
            ::QString cppArg0;
            pythonToCpp[0](pyArgs[0], &cppArg0);
            quint16 cppArg1;
            pythonToCpp[1](pyArgs[1], &cppArg1);
            ::QFlags<QIODeviceBase::OpenModeFlag> cppArg2(QIODeviceBase::OpenModeFlag::ReadWrite);
            if (pythonToCpp[2])
                pythonToCpp[2](pyArgs[2], &cppArg2);
            ::QAbstractSocket::NetworkLayerProtocol cppArg3(QAbstractSocket::NetworkLayerProtocol::AnyIPProtocol);
            if (pythonToCpp[3])
                pythonToCpp[3](pyArgs[3], &cppArg3);

            if (!PyErr_Occurred()) {
                // connectToHostEncrypted(QString,quint16,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
                PyThreadState *_save = PyEval_SaveThread(); // Py_BEGIN_ALLOW_THREADS
                cppSelf->connectToHostEncrypted(cppArg0, cppArg1, cppArg2, cppArg3);
                PyEval_RestoreThread(_save); // Py_END_ALLOW_THREADS
            }
            break;
        }
        case 1: // connectToHostEncrypted(const QString & hostName, quint16 port, const QString & sslPeerName, QFlags<QIODeviceBase::OpenModeFlag> mode, QAbstractSocket::NetworkLayerProtocol protocol)
        {
            if (kwds && PyDict_Size(kwds) > 0) {
                PyObject *value{};
                Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
                static PyObject *const key_mode = Shiboken::String::createStaticString("mode");
                if (PyDict_Contains(kwds, key_mode)) {
                    value = PyDict_GetItem(kwds, key_mode);
                    if (value && pyArgs[3]) {
                        errInfo.reset(key_mode);
                        Py_INCREF(errInfo.object());
                        goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
                    }
                    if (value) {
                        pyArgs[3] = value;
                        if (!(pythonToCpp[3] = Shiboken::Conversions::pythonToCppConversion(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, (pyArgs[3]))))
                            goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
                    }
                    PyDict_DelItem(kwds_dup, key_mode);
                }
                static PyObject *const key_protocol = Shiboken::String::createStaticString("protocol");
                if (PyDict_Contains(kwds, key_protocol)) {
                    value = PyDict_GetItem(kwds, key_protocol);
                    if (value && pyArgs[4]) {
                        errInfo.reset(key_protocol);
                        Py_INCREF(errInfo.object());
                        goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
                    }
                    if (value) {
                        pyArgs[4] = value;
                        if (!(pythonToCpp[4] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_NETWORKLAYERPROTOCOL_IDX]))->converter, (pyArgs[4]))))
                            goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
                    }
                    PyDict_DelItem(kwds_dup, key_protocol);
                }
                if (PyDict_Size(kwds_dup) > 0) {
                    errInfo.reset(kwds_dup.release());
                    goto Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError;
                }
            }
            ::QString cppArg0;
            pythonToCpp[0](pyArgs[0], &cppArg0);
            quint16 cppArg1;
            pythonToCpp[1](pyArgs[1], &cppArg1);
            ::QString cppArg2;
            pythonToCpp[2](pyArgs[2], &cppArg2);
            ::QFlags<QIODeviceBase::OpenModeFlag> cppArg3(QIODeviceBase::OpenModeFlag::ReadWrite);
            if (pythonToCpp[3])
                pythonToCpp[3](pyArgs[3], &cppArg3);
            ::QAbstractSocket::NetworkLayerProtocol cppArg4(QAbstractSocket::NetworkLayerProtocol::AnyIPProtocol);
            if (pythonToCpp[4])
                pythonToCpp[4](pyArgs[4], &cppArg4);

            if (!PyErr_Occurred()) {
                // connectToHostEncrypted(QString,quint16,QString,QFlags<QIODeviceBase::OpenModeFlag>,QAbstractSocket::NetworkLayerProtocol)
                cppSelf->connectToHostEncrypted(cppArg0, cppArg1, cppArg2, cppArg3, cppArg4);
            }
            break;
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_connectToHostEncrypted_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_continueInterruptedHandshake(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.continueInterruptedHandshake";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // continueInterruptedHandshake()
            cppSelf->continueInterruptedHandshake();
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;
}

static PyObject *Sbk_QSslSocketFunc_disconnectFromHost(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.disconnectFromHost";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // disconnectFromHost()
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::disconnectFromHost()
                : cppSelf->disconnectFromHost();
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;
}

static PyObject *Sbk_QSslSocketFunc_encryptedBytesAvailable(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.encryptedBytesAvailable";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // encryptedBytesAvailable()const
            qint64 cppResult = const_cast<const ::QSslSocket *>(cppSelf)->encryptedBytesAvailable();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_encryptedBytesToWrite(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.encryptedBytesToWrite";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // encryptedBytesToWrite()const
            qint64 cppResult = const_cast<const ::QSslSocket *>(cppSelf)->encryptedBytesToWrite();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_ignoreSslErrors(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.ignoreSslErrors";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths


    if (!PyArg_UnpackTuple(args, "ignoreSslErrors", 0, 1, &(pyArgs[0])))
        return {};


    // Overloaded function decisor
    // 0: QSslSocket::ignoreSslErrors()
    // 1: QSslSocket::ignoreSslErrors(QList<QSslError>)
    if (numArgs == 0) {
        overloadId = 0; // ignoreSslErrors()
    } else if (numArgs == 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QSSLERROR_IDX], (pyArgs[0])))) {
        overloadId = 1; // ignoreSslErrors(QList<QSslError>)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_ignoreSslErrors_TypeError;

    // Call function/method
    switch (overloadId) {
        case 0: // ignoreSslErrors()
        {

            if (!PyErr_Occurred()) {
                // ignoreSslErrors()
                cppSelf->ignoreSslErrors();
            }
            break;
        }
        case 1: // ignoreSslErrors(const QList<QSslError > & errors)
        {
            ::QList<QSslError > cppArg0;
            pythonToCpp[0](pyArgs[0], &cppArg0);

            if (!PyErr_Occurred()) {
                // ignoreSslErrors(QList<QSslError>)
                cppSelf->ignoreSslErrors(cppArg0);
            }
            break;
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_ignoreSslErrors_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_implementedClasses(PyObject *self, PyObject *args, PyObject *kwds)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.implementedClasses";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths
    if (numArgs > 1) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_implementedClasses_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|O:implementedClasses", &(pyArgs[0])))
        return {};


    // Overloaded function decisor
    // 0: static QSslSocket::implementedClasses(QString)->QList< QSsl::ImplementedClass >
    if (numArgs == 0) {
        overloadId = 0; // implementedClasses(QString)
    } else if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0])))) {
        overloadId = 0; // implementedClasses(QString)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_implementedClasses_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_backendName = Shiboken::String::createStaticString("backendName");
            if (PyDict_Contains(kwds, key_backendName)) {
                value = PyDict_GetItem(kwds, key_backendName);
                if (value && pyArgs[0]) {
                    errInfo.reset(key_backendName);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_implementedClasses_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0]))))
                        goto Sbk_QSslSocketFunc_implementedClasses_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_backendName);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_implementedClasses_TypeError;
            }
        }
        ::QString cppArg0{};
        if (pythonToCpp[0])
            pythonToCpp[0](pyArgs[0], &cppArg0);

        if (!PyErr_Occurred()) {
            // implementedClasses(QString)
            QList<QSsl::ImplementedClass > cppResult = ::QSslSocket::implementedClasses(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QSSL_IMPLEMENTEDCLASS_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_implementedClasses_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_isClassImplemented(PyObject *self, PyObject *args, PyObject *kwds)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.isClassImplemented";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0};

    // invalid argument lengths
    if (numArgs > 2) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_isClassImplemented_TypeError;
    } else if (numArgs < 1) {
        static PyObject *const too_few = Shiboken::String::createStaticString("<");
        errInfo.reset(too_few);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_isClassImplemented_TypeError;
    }

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


    // Overloaded function decisor
    // 0: static QSslSocket::isClassImplemented(QSsl::ImplementedClass,QString)->bool
    if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_IMPLEMENTEDCLASS_IDX]))->converter, (pyArgs[0])))) {
        if (numArgs == 1) {
            overloadId = 0; // isClassImplemented(QSsl::ImplementedClass,QString)
        } else if (numArgs >= 2
            && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[1])))) {
            overloadId = 0; // isClassImplemented(QSsl::ImplementedClass,QString)
        }
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_isClassImplemented_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_backendName = Shiboken::String::createStaticString("backendName");
            if (PyDict_Contains(kwds, key_backendName)) {
                value = PyDict_GetItem(kwds, key_backendName);
                if (value && pyArgs[1]) {
                    errInfo.reset(key_backendName);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_isClassImplemented_TypeError;
                }
                if (value) {
                    pyArgs[1] = value;
                    if (!(pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[1]))))
                        goto Sbk_QSslSocketFunc_isClassImplemented_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_backendName);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_isClassImplemented_TypeError;
            }
        }
        ::QSsl::ImplementedClass cppArg0{QSsl::ImplementedClass::Key};
        pythonToCpp[0](pyArgs[0], &cppArg0);
        ::QString cppArg1{};
        if (pythonToCpp[1])
            pythonToCpp[1](pyArgs[1], &cppArg1);

        if (!PyErr_Occurred()) {
            // isClassImplemented(QSsl::ImplementedClass,QString)
            bool cppResult = ::QSslSocket::isClassImplemented(cppArg0, cppArg1);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_isClassImplemented_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_isEncrypted(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.isEncrypted";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // isEncrypted()const
            bool cppResult = const_cast<const ::QSslSocket *>(cppSelf)->isEncrypted();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_isFeatureSupported(PyObject *self, PyObject *args, PyObject *kwds)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.isFeatureSupported";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0};

    // invalid argument lengths
    if (numArgs > 2) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_isFeatureSupported_TypeError;
    } else if (numArgs < 1) {
        static PyObject *const too_few = Shiboken::String::createStaticString("<");
        errInfo.reset(too_few);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_isFeatureSupported_TypeError;
    }

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


    // Overloaded function decisor
    // 0: static QSslSocket::isFeatureSupported(QSsl::SupportedFeature,QString)->bool
    if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_SUPPORTEDFEATURE_IDX]))->converter, (pyArgs[0])))) {
        if (numArgs == 1) {
            overloadId = 0; // isFeatureSupported(QSsl::SupportedFeature,QString)
        } else if (numArgs >= 2
            && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[1])))) {
            overloadId = 0; // isFeatureSupported(QSsl::SupportedFeature,QString)
        }
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_isFeatureSupported_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_backendName = Shiboken::String::createStaticString("backendName");
            if (PyDict_Contains(kwds, key_backendName)) {
                value = PyDict_GetItem(kwds, key_backendName);
                if (value && pyArgs[1]) {
                    errInfo.reset(key_backendName);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_isFeatureSupported_TypeError;
                }
                if (value) {
                    pyArgs[1] = value;
                    if (!(pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[1]))))
                        goto Sbk_QSslSocketFunc_isFeatureSupported_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_backendName);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_isFeatureSupported_TypeError;
            }
        }
        ::QSsl::SupportedFeature cppArg0{QSsl::SupportedFeature::CertificateVerification};
        pythonToCpp[0](pyArgs[0], &cppArg0);
        ::QString cppArg1{};
        if (pythonToCpp[1])
            pythonToCpp[1](pyArgs[1], &cppArg1);

        if (!PyErr_Occurred()) {
            // isFeatureSupported(QSsl::SupportedFeature,QString)
            bool cppResult = ::QSslSocket::isFeatureSupported(cppArg0, cppArg1);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_isFeatureSupported_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_isProtocolSupported(PyObject *self, PyObject *args, PyObject *kwds)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.isProtocolSupported";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0};

    // invalid argument lengths
    if (numArgs > 2) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_isProtocolSupported_TypeError;
    } else if (numArgs < 1) {
        static PyObject *const too_few = Shiboken::String::createStaticString("<");
        errInfo.reset(too_few);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_isProtocolSupported_TypeError;
    }

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


    // Overloaded function decisor
    // 0: static QSslSocket::isProtocolSupported(QSsl::SslProtocol,QString)->bool
    if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_SSLPROTOCOL_IDX]))->converter, (pyArgs[0])))) {
        if (numArgs == 1) {
            overloadId = 0; // isProtocolSupported(QSsl::SslProtocol,QString)
        } else if (numArgs >= 2
            && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[1])))) {
            overloadId = 0; // isProtocolSupported(QSsl::SslProtocol,QString)
        }
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_isProtocolSupported_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_backendName = Shiboken::String::createStaticString("backendName");
            if (PyDict_Contains(kwds, key_backendName)) {
                value = PyDict_GetItem(kwds, key_backendName);
                if (value && pyArgs[1]) {
                    errInfo.reset(key_backendName);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_isProtocolSupported_TypeError;
                }
                if (value) {
                    pyArgs[1] = value;
                    if (!(pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[1]))))
                        goto Sbk_QSslSocketFunc_isProtocolSupported_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_backendName);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_isProtocolSupported_TypeError;
            }
        }
        ::QSsl::SslProtocol cppArg0{QSsl::TlsV1_0};
        pythonToCpp[0](pyArgs[0], &cppArg0);
        ::QString cppArg1{};
        if (pythonToCpp[1])
            pythonToCpp[1](pyArgs[1], &cppArg1);

        if (!PyErr_Occurred()) {
            // isProtocolSupported(QSsl::SslProtocol,QString)
            bool cppResult = ::QSslSocket::isProtocolSupported(cppArg0, cppArg1);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_isProtocolSupported_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_localCertificate(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.localCertificate";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // localCertificate()const
            QSslCertificate cppResult = const_cast<const ::QSslSocket *>(cppSelf)->localCertificate();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypes[SBK_QSSLCERTIFICATE_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_localCertificateChain(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.localCertificateChain";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // localCertificateChain()const
            QList<QSslCertificate > cppResult = const_cast<const ::QSslSocket *>(cppSelf)->localCertificateChain();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QSSLCERTIFICATE_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_mode(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.mode";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // mode()const
            QSslSocket::SslMode cppResult = const_cast<const ::QSslSocket *>(cppSelf)->mode();
            pyResult = Shiboken::Conversions::copyToPython(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_SSLMODE_IDX]))->converter, &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_ocspResponses(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.ocspResponses";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // ocspResponses()const
            QList<QOcspResponse > cppResult = const_cast<const ::QSslSocket *>(cppSelf)->ocspResponses();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QOCSPRESPONSE_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_peerCertificate(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.peerCertificate";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // peerCertificate()const
            QSslCertificate cppResult = const_cast<const ::QSslSocket *>(cppSelf)->peerCertificate();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypes[SBK_QSSLCERTIFICATE_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_peerCertificateChain(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.peerCertificateChain";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // peerCertificateChain()const
            QList<QSslCertificate > cppResult = const_cast<const ::QSslSocket *>(cppSelf)->peerCertificateChain();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QSSLCERTIFICATE_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_peerVerifyDepth(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.peerVerifyDepth";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // peerVerifyDepth()const
            int cppResult = const_cast<const ::QSslSocket *>(cppSelf)->peerVerifyDepth();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<int>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_peerVerifyMode(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.peerVerifyMode";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // peerVerifyMode()const
            QSslSocket::PeerVerifyMode cppResult = const_cast<const ::QSslSocket *>(cppSelf)->peerVerifyMode();
            pyResult = Shiboken::Conversions::copyToPython(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX]))->converter, &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_peerVerifyName(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.peerVerifyName";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // peerVerifyName()const
            QString cppResult = const_cast<const ::QSslSocket *>(cppSelf)->peerVerifyName();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_privateKey(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.privateKey";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // privateKey()const
            QSslKey cppResult = const_cast<const ::QSslSocket *>(cppSelf)->privateKey();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypes[SBK_QSSLKEY_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_protocol(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.protocol";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // protocol()const
            QSsl::SslProtocol cppResult = const_cast<const ::QSslSocket *>(cppSelf)->protocol();
            pyResult = Shiboken::Conversions::copyToPython(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_SSLPROTOCOL_IDX]))->converter, &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_readData(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.readData";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QIODevice::readData(char*,qint64)->PyObject
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), (pyArg)))) {
        overloadId = 0; // readData(char*,qint64)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_readData_TypeError;

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

        if (!PyErr_Occurred()) {
            // readData(char*,qint64)
            // Begin code injection
            // ========================================================================
            // START of custom code block [file: ../glue/qtcore.cpp (qiodevice-readData)]
            QByteArray ba(1 + qsizetype(cppArg0), char(0));
            Py_BEGIN_ALLOW_THREADS
            (Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self)) ? cppSelf->::QSslSocket::readData(ba.data(), qint64(cppArg0)) : cppSelf->readData(ba.data(), qint64(cppArg0)));
            Py_END_ALLOW_THREADS
            pyResult = Shiboken::String::fromCString(ba.constData());
            // END of custom code block [file: ../glue/qtcore.cpp (qiodevice-readData)]
            // ========================================================================
            // End of code injection

        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_readData_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_resume(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.resume";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // resume()
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::resume()
                : cppSelf->resume();
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;
}

static PyObject *Sbk_QSslSocketFunc_sessionCipher(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.sessionCipher";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // sessionCipher()const
            QSslCipher cppResult = const_cast<const ::QSslSocket *>(cppSelf)->sessionCipher();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypes[SBK_QSSLCIPHER_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_sessionProtocol(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.sessionProtocol";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // sessionProtocol()const
            QSsl::SslProtocol cppResult = const_cast<const ::QSslSocket *>(cppSelf)->sessionProtocol();
            pyResult = Shiboken::Conversions::copyToPython(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_SSLPROTOCOL_IDX]))->converter, &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_setActiveBackend(PyObject *self, PyObject *pyArg)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setActiveBackend";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: static QSslSocket::setActiveBackend(QString)->bool
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArg)))) {
        overloadId = 0; // setActiveBackend(QString)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setActiveBackend_TypeError;

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

        if (!PyErr_Occurred()) {
            // setActiveBackend(QString)
            bool cppResult = ::QSslSocket::setActiveBackend(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_setActiveBackend_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_setLocalCertificate(PyObject *self, PyObject *args, PyObject *kwds)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setLocalCertificate";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0};

    // invalid argument lengths
    if (numArgs > 2) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_setLocalCertificate_TypeError;
    } else if (numArgs < 1) {
        static PyObject *const too_few = Shiboken::String::createStaticString("<");
        errInfo.reset(too_few);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_setLocalCertificate_TypeError;
    }

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


    // Overloaded function decisor
    // 0: QSslSocket::setLocalCertificate(QSslCertificate)
    // 1: QSslSocket::setLocalCertificate(QString,QSsl::EncodingFormat)
    if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0])))) {
        if (numArgs == 1) {
            overloadId = 1; // setLocalCertificate(QString,QSsl::EncodingFormat)
        } else if (numArgs >= 2
            && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_ENCODINGFORMAT_IDX]))->converter, (pyArgs[1])))) {
            overloadId = 1; // setLocalCertificate(QString,QSsl::EncodingFormat)
        }
    } else if (numArgs == 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtNetworkTypes[SBK_QSSLCERTIFICATE_IDX], (pyArgs[0])))) {
        overloadId = 0; // setLocalCertificate(QSslCertificate)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setLocalCertificate_TypeError;

    // Call function/method
    switch (overloadId) {
        case 0: // setLocalCertificate(const QSslCertificate & certificate)
        {
            if (kwds && PyDict_Size(kwds) > 0) {
                errInfo.reset(kwds);
                Py_INCREF(errInfo.object());
                goto Sbk_QSslSocketFunc_setLocalCertificate_TypeError;
            }
            if (!Shiboken::Object::isValid(pyArgs[0]))
                return {};
            ::QSslCertificate cppArg0_local;
            ::QSslCertificate *cppArg0 = &cppArg0_local;
            if (pythonToCpp[0].isValue())
                pythonToCpp[0](pyArgs[0], &cppArg0_local);
            else
                pythonToCpp[0](pyArgs[0], &cppArg0);


            if (!PyErr_Occurred()) {
                // setLocalCertificate(QSslCertificate)
                cppSelf->setLocalCertificate(*cppArg0);
            }
            break;
        }
        case 1: // setLocalCertificate(const QString & fileName, QSsl::EncodingFormat format)
        {
            if (kwds && PyDict_Size(kwds) > 0) {
                PyObject *value{};
                Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
                static PyObject *const key_format = Shiboken::String::createStaticString("format");
                if (PyDict_Contains(kwds, key_format)) {
                    value = PyDict_GetItem(kwds, key_format);
                    if (value && pyArgs[1]) {
                        errInfo.reset(key_format);
                        Py_INCREF(errInfo.object());
                        goto Sbk_QSslSocketFunc_setLocalCertificate_TypeError;
                    }
                    if (value) {
                        pyArgs[1] = value;
                        if (!(pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_ENCODINGFORMAT_IDX]))->converter, (pyArgs[1]))))
                            goto Sbk_QSslSocketFunc_setLocalCertificate_TypeError;
                    }
                    PyDict_DelItem(kwds_dup, key_format);
                }
                if (PyDict_Size(kwds_dup) > 0) {
                    errInfo.reset(kwds_dup.release());
                    goto Sbk_QSslSocketFunc_setLocalCertificate_TypeError;
                }
            }
            ::QString cppArg0;
            pythonToCpp[0](pyArgs[0], &cppArg0);
            ::QSsl::EncodingFormat cppArg1(QSsl::Pem);
            if (pythonToCpp[1])
                pythonToCpp[1](pyArgs[1], &cppArg1);

            if (!PyErr_Occurred()) {
                // setLocalCertificate(QString,QSsl::EncodingFormat)
                cppSelf->setLocalCertificate(cppArg0, cppArg1);
            }
            break;
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_setLocalCertificate_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_setLocalCertificateChain(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setLocalCertificateChain";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QSslSocket::setLocalCertificateChain(QList<QSslCertificate>)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QSSLCERTIFICATE_IDX], (pyArg)))) {
        overloadId = 0; // setLocalCertificateChain(QList<QSslCertificate>)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setLocalCertificateChain_TypeError;

    // Call function/method
    {
        ::QList<QSslCertificate > cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setLocalCertificateChain(QList<QSslCertificate>)
            cppSelf->setLocalCertificateChain(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_setLocalCertificateChain_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_setPeerVerifyDepth(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setPeerVerifyDepth";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QSslSocket::setPeerVerifyDepth(int)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArg)))) {
        overloadId = 0; // setPeerVerifyDepth(int)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setPeerVerifyDepth_TypeError;

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

        if (!PyErr_Occurred()) {
            // setPeerVerifyDepth(int)
            cppSelf->setPeerVerifyDepth(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_setPeerVerifyDepth_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_setPeerVerifyMode(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setPeerVerifyMode";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QSslSocket::setPeerVerifyMode(QSslSocket::PeerVerifyMode)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX]))->converter, (pyArg)))) {
        overloadId = 0; // setPeerVerifyMode(QSslSocket::PeerVerifyMode)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setPeerVerifyMode_TypeError;

    // Call function/method
    {
        ::QSslSocket::PeerVerifyMode cppArg0{QSslSocket::VerifyNone};
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setPeerVerifyMode(QSslSocket::PeerVerifyMode)
            cppSelf->setPeerVerifyMode(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_setPeerVerifyMode_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_setPeerVerifyName(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setPeerVerifyName";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QSslSocket::setPeerVerifyName(QString)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArg)))) {
        overloadId = 0; // setPeerVerifyName(QString)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setPeerVerifyName_TypeError;

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

        if (!PyErr_Occurred()) {
            // setPeerVerifyName(QString)
            cppSelf->setPeerVerifyName(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_setPeerVerifyName_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_setPrivateKey(PyObject *self, PyObject *args, PyObject *kwds)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setPrivateKey";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[4];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0, 0, 0};

    // invalid argument lengths
    if (numArgs > 4) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_setPrivateKey_TypeError;
    } else if (numArgs < 1) {
        static PyObject *const too_few = Shiboken::String::createStaticString("<");
        errInfo.reset(too_few);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_setPrivateKey_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|OOOO:setPrivateKey", &(pyArgs[0]), &(pyArgs[1]), &(pyArgs[2]), &(pyArgs[3])))
        return {};


    // Overloaded function decisor
    // 0: QSslSocket::setPrivateKey(QSslKey)
    // 1: QSslSocket::setPrivateKey(QString,QSsl::KeyAlgorithm,QSsl::EncodingFormat,QByteArray)
    if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0])))) {
        if (numArgs == 1) {
            overloadId = 1; // setPrivateKey(QString,QSsl::KeyAlgorithm,QSsl::EncodingFormat,QByteArray)
        } else if (numArgs >= 2
            && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_KEYALGORITHM_IDX]))->converter, (pyArgs[1])))) {
            if (numArgs == 2) {
                overloadId = 1; // setPrivateKey(QString,QSsl::KeyAlgorithm,QSsl::EncodingFormat,QByteArray)
            } else if (numArgs >= 3
                && (pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_ENCODINGFORMAT_IDX]))->converter, (pyArgs[2])))) {
                if (numArgs == 3) {
                    overloadId = 1; // setPrivateKey(QString,QSsl::KeyAlgorithm,QSsl::EncodingFormat,QByteArray)
                } else if (numArgs >= 4
                    && (pythonToCpp[3] = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QBYTEARRAY_IDX], (pyArgs[3])))) {
                    overloadId = 1; // setPrivateKey(QString,QSsl::KeyAlgorithm,QSsl::EncodingFormat,QByteArray)
                }
            }
        }
    } else if (numArgs == 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtNetworkTypes[SBK_QSSLKEY_IDX], (pyArgs[0])))) {
        overloadId = 0; // setPrivateKey(QSslKey)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setPrivateKey_TypeError;

    // Call function/method
    switch (overloadId) {
        case 0: // setPrivateKey(const QSslKey & key)
        {
            if (kwds && PyDict_Size(kwds) > 0) {
                errInfo.reset(kwds);
                Py_INCREF(errInfo.object());
                goto Sbk_QSslSocketFunc_setPrivateKey_TypeError;
            }
            if (!Shiboken::Object::isValid(pyArgs[0]))
                return {};
            ::QSslKey cppArg0_local;
            ::QSslKey *cppArg0 = &cppArg0_local;
            if (pythonToCpp[0].isValue())
                pythonToCpp[0](pyArgs[0], &cppArg0_local);
            else
                pythonToCpp[0](pyArgs[0], &cppArg0);


            if (!PyErr_Occurred()) {
                // setPrivateKey(QSslKey)
                cppSelf->setPrivateKey(*cppArg0);
            }
            break;
        }
        case 1: // setPrivateKey(const QString & fileName, QSsl::KeyAlgorithm algorithm, QSsl::EncodingFormat format, const QByteArray & passPhrase)
        {
            if (kwds && PyDict_Size(kwds) > 0) {
                PyObject *value{};
                Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
                static PyObject *const key_algorithm = Shiboken::String::createStaticString("algorithm");
                if (PyDict_Contains(kwds, key_algorithm)) {
                    value = PyDict_GetItem(kwds, key_algorithm);
                    if (value && pyArgs[1]) {
                        errInfo.reset(key_algorithm);
                        Py_INCREF(errInfo.object());
                        goto Sbk_QSslSocketFunc_setPrivateKey_TypeError;
                    }
                    if (value) {
                        pyArgs[1] = value;
                        if (!(pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_KEYALGORITHM_IDX]))->converter, (pyArgs[1]))))
                            goto Sbk_QSslSocketFunc_setPrivateKey_TypeError;
                    }
                    PyDict_DelItem(kwds_dup, key_algorithm);
                }
                static PyObject *const key_format = Shiboken::String::createStaticString("format");
                if (PyDict_Contains(kwds, key_format)) {
                    value = PyDict_GetItem(kwds, key_format);
                    if (value && pyArgs[2]) {
                        errInfo.reset(key_format);
                        Py_INCREF(errInfo.object());
                        goto Sbk_QSslSocketFunc_setPrivateKey_TypeError;
                    }
                    if (value) {
                        pyArgs[2] = value;
                        if (!(pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_ENCODINGFORMAT_IDX]))->converter, (pyArgs[2]))))
                            goto Sbk_QSslSocketFunc_setPrivateKey_TypeError;
                    }
                    PyDict_DelItem(kwds_dup, key_format);
                }
                static PyObject *const key_passPhrase = Shiboken::String::createStaticString("passPhrase");
                if (PyDict_Contains(kwds, key_passPhrase)) {
                    value = PyDict_GetItem(kwds, key_passPhrase);
                    if (value && pyArgs[3]) {
                        errInfo.reset(key_passPhrase);
                        Py_INCREF(errInfo.object());
                        goto Sbk_QSslSocketFunc_setPrivateKey_TypeError;
                    }
                    if (value) {
                        pyArgs[3] = value;
                        if (!(pythonToCpp[3] = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QBYTEARRAY_IDX], (pyArgs[3]))))
                            goto Sbk_QSslSocketFunc_setPrivateKey_TypeError;
                    }
                    PyDict_DelItem(kwds_dup, key_passPhrase);
                }
                if (PyDict_Size(kwds_dup) > 0) {
                    errInfo.reset(kwds_dup.release());
                    goto Sbk_QSslSocketFunc_setPrivateKey_TypeError;
                }
            }
            ::QString cppArg0;
            pythonToCpp[0](pyArgs[0], &cppArg0);
            ::QSsl::KeyAlgorithm cppArg1(QSsl::Rsa);
            if (pythonToCpp[1])
                pythonToCpp[1](pyArgs[1], &cppArg1);
            ::QSsl::EncodingFormat cppArg2(QSsl::Pem);
            if (pythonToCpp[2])
                pythonToCpp[2](pyArgs[2], &cppArg2);
            if (!Shiboken::Object::isValid(pyArgs[3]))
                return {};
            ::QByteArray cppArg3_local = QByteArray();
            ::QByteArray *cppArg3 = &cppArg3_local;
            if (pythonToCpp[3]) {
                if (pythonToCpp[3].isValue())
                    pythonToCpp[3](pyArgs[3], &cppArg3_local);
                else
                    pythonToCpp[3](pyArgs[3], &cppArg3);
                }

            if (!PyErr_Occurred()) {
                // setPrivateKey(QString,QSsl::KeyAlgorithm,QSsl::EncodingFormat,QByteArray)
                cppSelf->setPrivateKey(cppArg0, cppArg1, cppArg2, *cppArg3);
            }
            break;
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_setPrivateKey_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_setProtocol(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setProtocol";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QSslSocket::setProtocol(QSsl::SslProtocol)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QSSL_SSLPROTOCOL_IDX]))->converter, (pyArg)))) {
        overloadId = 0; // setProtocol(QSsl::SslProtocol)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setProtocol_TypeError;

    // Call function/method
    {
        ::QSsl::SslProtocol cppArg0{QSsl::TlsV1_0};
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setProtocol(QSsl::SslProtocol)
            cppSelf->setProtocol(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_setProtocol_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_setReadBufferSize(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setReadBufferSize";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QAbstractSocket::setReadBufferSize(qint64)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), (pyArg)))) {
        overloadId = 0; // setReadBufferSize(qint64)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setReadBufferSize_TypeError;

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

        if (!PyErr_Occurred()) {
            // setReadBufferSize(qint64)
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::setReadBufferSize(cppArg0)
                : cppSelf->setReadBufferSize(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_setReadBufferSize_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_setSocketDescriptor(PyObject *self, PyObject *args, PyObject *kwds)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setSocketDescriptor";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[3];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0, 0};

    // invalid argument lengths
    if (numArgs > 3) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_setSocketDescriptor_TypeError;
    } else if (numArgs < 1) {
        static PyObject *const too_few = Shiboken::String::createStaticString("<");
        errInfo.reset(too_few);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_setSocketDescriptor_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|OOO:setSocketDescriptor", &(pyArgs[0]), &(pyArgs[1]), &(pyArgs[2])))
        return {};


    // Overloaded function decisor
    // 0: QAbstractSocket::setSocketDescriptor(qintptr,QAbstractSocket::SocketState,QFlags<QIODeviceBase::OpenModeFlag>)->bool
    if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QINTPTR_IDX], (pyArgs[0])))) {
        if (numArgs == 1) {
            overloadId = 0; // setSocketDescriptor(qintptr,QAbstractSocket::SocketState,QFlags<QIODeviceBase::OpenModeFlag>)
        } else if (numArgs >= 2
            && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_SOCKETSTATE_IDX]))->converter, (pyArgs[1])))) {
            if (numArgs == 2) {
                overloadId = 0; // setSocketDescriptor(qintptr,QAbstractSocket::SocketState,QFlags<QIODeviceBase::OpenModeFlag>)
            } else if (numArgs >= 3
                && (pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, (pyArgs[2])))) {
                overloadId = 0; // setSocketDescriptor(qintptr,QAbstractSocket::SocketState,QFlags<QIODeviceBase::OpenModeFlag>)
            }
        }
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setSocketDescriptor_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_state = Shiboken::String::createStaticString("state");
            if (PyDict_Contains(kwds, key_state)) {
                value = PyDict_GetItem(kwds, key_state);
                if (value && pyArgs[1]) {
                    errInfo.reset(key_state);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_setSocketDescriptor_TypeError;
                }
                if (value) {
                    pyArgs[1] = value;
                    if (!(pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_SOCKETSTATE_IDX]))->converter, (pyArgs[1]))))
                        goto Sbk_QSslSocketFunc_setSocketDescriptor_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_state);
            }
            static PyObject *const key_openMode = Shiboken::String::createStaticString("openMode");
            if (PyDict_Contains(kwds, key_openMode)) {
                value = PyDict_GetItem(kwds, key_openMode);
                if (value && pyArgs[2]) {
                    errInfo.reset(key_openMode);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_setSocketDescriptor_TypeError;
                }
                if (value) {
                    pyArgs[2] = value;
                    if (!(pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(PepType_PFTP(reinterpret_cast<PySideQFlagsType *>(SbkPySide6_QtCoreTypes[SBK_QFLAGS_QIODEVICEBASE_OPENMODEFLAG_IDX]))->converter, (pyArgs[2]))))
                        goto Sbk_QSslSocketFunc_setSocketDescriptor_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_openMode);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_setSocketDescriptor_TypeError;
            }
        }
        ::qintptr cppArg0;
        pythonToCpp[0](pyArgs[0], &cppArg0);
        ::QAbstractSocket::SocketState cppArg1(QAbstractSocket::SocketState::ConnectedState);
        if (pythonToCpp[1])
            pythonToCpp[1](pyArgs[1], &cppArg1);
        ::QFlags<QIODeviceBase::OpenModeFlag> cppArg2(QIODeviceBase::OpenModeFlag::ReadWrite);
        if (pythonToCpp[2])
            pythonToCpp[2](pyArgs[2], &cppArg2);

        if (!PyErr_Occurred()) {
            // setSocketDescriptor(qintptr,QAbstractSocket::SocketState,QFlags<QIODeviceBase::OpenModeFlag>)
            bool cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::setSocketDescriptor(cppArg0, cppArg1, cppArg2)
                : cppSelf->setSocketDescriptor(cppArg0, cppArg1, cppArg2);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_setSocketDescriptor_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_setSocketOption(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setSocketOption";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0};

    // invalid argument lengths


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


    // Overloaded function decisor
    // 0: QAbstractSocket::setSocketOption(QAbstractSocket::SocketOption,QVariant)
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_SOCKETOPTION_IDX]))->converter, (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QVARIANT_IDX], (pyArgs[1])))) {
        overloadId = 0; // setSocketOption(QAbstractSocket::SocketOption,QVariant)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setSocketOption_TypeError;

    // Call function/method
    {
        ::QAbstractSocket::SocketOption cppArg0{QAbstractSocket::LowDelayOption};
        pythonToCpp[0](pyArgs[0], &cppArg0);
        ::QVariant cppArg1;
        pythonToCpp[1](pyArgs[1], &cppArg1);

        if (!PyErr_Occurred()) {
            // setSocketOption(QAbstractSocket::SocketOption,QVariant)
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::setSocketOption(cppArg0, cppArg1)
                : cppSelf->setSocketOption(cppArg0, cppArg1);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_setSocketOption_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_setSslConfiguration(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.setSslConfiguration";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QSslSocket::setSslConfiguration(QSslConfiguration)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtNetworkTypes[SBK_QSSLCONFIGURATION_IDX], (pyArg)))) {
        overloadId = 0; // setSslConfiguration(QSslConfiguration)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_setSslConfiguration_TypeError;

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


        if (!PyErr_Occurred()) {
            // setSslConfiguration(QSslConfiguration)
            cppSelf->setSslConfiguration(*cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QSslSocketFunc_setSslConfiguration_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_skipData(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.skipData";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QIODevice::skipData(qint64)->qint64
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), (pyArg)))) {
        overloadId = 0; // skipData(qint64)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_skipData_TypeError;

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

        if (!PyErr_Occurred()) {
            // skipData(qint64)
            qint64 cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::skipData(cppArg0)
                : cppSelf->skipData(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_skipData_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_socketOption(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.socketOption";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QAbstractSocket::socketOption(QAbstractSocket::SocketOption)->QVariant
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_SOCKETOPTION_IDX]))->converter, (pyArg)))) {
        overloadId = 0; // socketOption(QAbstractSocket::SocketOption)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_socketOption_TypeError;

    // Call function/method
    {
        ::QAbstractSocket::SocketOption cppArg0{QAbstractSocket::LowDelayOption};
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // socketOption(QAbstractSocket::SocketOption)
            QVariant cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::socketOption(cppArg0)
                : cppSelf->socketOption(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QVARIANT_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_socketOption_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_sslConfiguration(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.sslConfiguration";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // sslConfiguration()const
            QSslConfiguration cppResult = const_cast<const ::QSslSocket *>(cppSelf)->sslConfiguration();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypes[SBK_QSSLCONFIGURATION_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_sslHandshakeErrors(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.sslHandshakeErrors";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // sslHandshakeErrors()const
            QList<QSslError > cppResult = const_cast<const ::QSslSocket *>(cppSelf)->sslHandshakeErrors();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QSSLERROR_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_sslLibraryBuildVersionNumber(PyObject *self)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.sslLibraryBuildVersionNumber";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // sslLibraryBuildVersionNumber()
            long cppResult = ::QSslSocket::sslLibraryBuildVersionNumber();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<long>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_sslLibraryBuildVersionString(PyObject *self)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.sslLibraryBuildVersionString";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // sslLibraryBuildVersionString()
            QString cppResult = ::QSslSocket::sslLibraryBuildVersionString();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_sslLibraryVersionNumber(PyObject *self)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.sslLibraryVersionNumber";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // sslLibraryVersionNumber()
            long cppResult = ::QSslSocket::sslLibraryVersionNumber();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<long>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_sslLibraryVersionString(PyObject *self)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.sslLibraryVersionString";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // sslLibraryVersionString()
            QString cppResult = ::QSslSocket::sslLibraryVersionString();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_startClientEncryption(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.startClientEncryption";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // startClientEncryption()
            cppSelf->startClientEncryption();
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;
}

static PyObject *Sbk_QSslSocketFunc_startServerEncryption(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.startServerEncryption";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // startServerEncryption()
            cppSelf->startServerEncryption();
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;
}

static PyObject *Sbk_QSslSocketFunc_supportedFeatures(PyObject *self, PyObject *args, PyObject *kwds)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.supportedFeatures";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths
    if (numArgs > 1) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_supportedFeatures_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|O:supportedFeatures", &(pyArgs[0])))
        return {};


    // Overloaded function decisor
    // 0: static QSslSocket::supportedFeatures(QString)->QList< QSsl::SupportedFeature >
    if (numArgs == 0) {
        overloadId = 0; // supportedFeatures(QString)
    } else if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0])))) {
        overloadId = 0; // supportedFeatures(QString)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_supportedFeatures_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_backendName = Shiboken::String::createStaticString("backendName");
            if (PyDict_Contains(kwds, key_backendName)) {
                value = PyDict_GetItem(kwds, key_backendName);
                if (value && pyArgs[0]) {
                    errInfo.reset(key_backendName);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_supportedFeatures_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0]))))
                        goto Sbk_QSslSocketFunc_supportedFeatures_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_backendName);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_supportedFeatures_TypeError;
            }
        }
        ::QString cppArg0{};
        if (pythonToCpp[0])
            pythonToCpp[0](pyArgs[0], &cppArg0);

        if (!PyErr_Occurred()) {
            // supportedFeatures(QString)
            QList<QSsl::SupportedFeature > cppResult = ::QSslSocket::supportedFeatures(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QSSL_SUPPORTEDFEATURE_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_supportedFeatures_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_supportedProtocols(PyObject *self, PyObject *args, PyObject *kwds)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.supportedProtocols";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths
    if (numArgs > 1) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_supportedProtocols_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|O:supportedProtocols", &(pyArgs[0])))
        return {};


    // Overloaded function decisor
    // 0: static QSslSocket::supportedProtocols(QString)->QList< QSsl::SslProtocol >
    if (numArgs == 0) {
        overloadId = 0; // supportedProtocols(QString)
    } else if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0])))) {
        overloadId = 0; // supportedProtocols(QString)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_supportedProtocols_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_backendName = Shiboken::String::createStaticString("backendName");
            if (PyDict_Contains(kwds, key_backendName)) {
                value = PyDict_GetItem(kwds, key_backendName);
                if (value && pyArgs[0]) {
                    errInfo.reset(key_backendName);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_supportedProtocols_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0]))))
                        goto Sbk_QSslSocketFunc_supportedProtocols_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_backendName);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_supportedProtocols_TypeError;
            }
        }
        ::QString cppArg0{};
        if (pythonToCpp[0])
            pythonToCpp[0](pyArgs[0], &cppArg0);

        if (!PyErr_Occurred()) {
            // supportedProtocols(QString)
            QList<QSsl::SslProtocol > cppResult = ::QSslSocket::supportedProtocols(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QSSL_SSLPROTOCOL_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_supportedProtocols_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_supportsSsl(PyObject *self)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.supportsSsl";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // supportsSsl()
            bool cppResult = ::QSslSocket::supportsSsl();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QSslSocketFunc_waitForBytesWritten(PyObject *self, PyObject *args, PyObject *kwds)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.waitForBytesWritten";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths
    if (numArgs > 1) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_waitForBytesWritten_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|O:waitForBytesWritten", &(pyArgs[0])))
        return {};


    // Overloaded function decisor
    // 0: QIODevice::waitForBytesWritten(int)->bool
    if (numArgs == 0) {
        overloadId = 0; // waitForBytesWritten(int)
    } else if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[0])))) {
        overloadId = 0; // waitForBytesWritten(int)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_waitForBytesWritten_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_msecs = Shiboken::String::createStaticString("msecs");
            if (PyDict_Contains(kwds, key_msecs)) {
                value = PyDict_GetItem(kwds, key_msecs);
                if (value && pyArgs[0]) {
                    errInfo.reset(key_msecs);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_waitForBytesWritten_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[0]))))
                        goto Sbk_QSslSocketFunc_waitForBytesWritten_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_msecs);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_waitForBytesWritten_TypeError;
            }
        }
        int cppArg0 = 30000;
        if (pythonToCpp[0])
            pythonToCpp[0](pyArgs[0], &cppArg0);

        if (!PyErr_Occurred()) {
            // waitForBytesWritten(int)
            bool cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::waitForBytesWritten(cppArg0)
                : cppSelf->waitForBytesWritten(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_waitForBytesWritten_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_waitForConnected(PyObject *self, PyObject *args, PyObject *kwds)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.waitForConnected";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths
    if (numArgs > 1) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_waitForConnected_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|O:waitForConnected", &(pyArgs[0])))
        return {};


    // Overloaded function decisor
    // 0: QAbstractSocket::waitForConnected(int)->bool
    if (numArgs == 0) {
        overloadId = 0; // waitForConnected(int)
    } else if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[0])))) {
        overloadId = 0; // waitForConnected(int)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_waitForConnected_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_msecs = Shiboken::String::createStaticString("msecs");
            if (PyDict_Contains(kwds, key_msecs)) {
                value = PyDict_GetItem(kwds, key_msecs);
                if (value && pyArgs[0]) {
                    errInfo.reset(key_msecs);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_waitForConnected_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[0]))))
                        goto Sbk_QSslSocketFunc_waitForConnected_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_msecs);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_waitForConnected_TypeError;
            }
        }
        int cppArg0 = 30000;
        if (pythonToCpp[0])
            pythonToCpp[0](pyArgs[0], &cppArg0);

        if (!PyErr_Occurred()) {
            // waitForConnected(int)
            bool cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::waitForConnected(cppArg0)
                : cppSelf->waitForConnected(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_waitForConnected_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_waitForDisconnected(PyObject *self, PyObject *args, PyObject *kwds)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.waitForDisconnected";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths
    if (numArgs > 1) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_waitForDisconnected_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|O:waitForDisconnected", &(pyArgs[0])))
        return {};


    // Overloaded function decisor
    // 0: QAbstractSocket::waitForDisconnected(int)->bool
    if (numArgs == 0) {
        overloadId = 0; // waitForDisconnected(int)
    } else if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[0])))) {
        overloadId = 0; // waitForDisconnected(int)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_waitForDisconnected_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_msecs = Shiboken::String::createStaticString("msecs");
            if (PyDict_Contains(kwds, key_msecs)) {
                value = PyDict_GetItem(kwds, key_msecs);
                if (value && pyArgs[0]) {
                    errInfo.reset(key_msecs);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_waitForDisconnected_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[0]))))
                        goto Sbk_QSslSocketFunc_waitForDisconnected_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_msecs);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_waitForDisconnected_TypeError;
            }
        }
        int cppArg0 = 30000;
        if (pythonToCpp[0])
            pythonToCpp[0](pyArgs[0], &cppArg0);

        if (!PyErr_Occurred()) {
            // waitForDisconnected(int)
            bool cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::waitForDisconnected(cppArg0)
                : cppSelf->waitForDisconnected(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_waitForDisconnected_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_waitForEncrypted(PyObject *self, PyObject *args, PyObject *kwds)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.waitForEncrypted";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths
    if (numArgs > 1) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_waitForEncrypted_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|O:waitForEncrypted", &(pyArgs[0])))
        return {};


    // Overloaded function decisor
    // 0: QSslSocket::waitForEncrypted(int)->bool
    if (numArgs == 0) {
        overloadId = 0; // waitForEncrypted(int)
    } else if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[0])))) {
        overloadId = 0; // waitForEncrypted(int)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_waitForEncrypted_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_msecs = Shiboken::String::createStaticString("msecs");
            if (PyDict_Contains(kwds, key_msecs)) {
                value = PyDict_GetItem(kwds, key_msecs);
                if (value && pyArgs[0]) {
                    errInfo.reset(key_msecs);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_waitForEncrypted_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[0]))))
                        goto Sbk_QSslSocketFunc_waitForEncrypted_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_msecs);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_waitForEncrypted_TypeError;
            }
        }
        int cppArg0 = 30000;
        if (pythonToCpp[0])
            pythonToCpp[0](pyArgs[0], &cppArg0);

        if (!PyErr_Occurred()) {
            // waitForEncrypted(int)
            PyThreadState *_save = PyEval_SaveThread(); // Py_BEGIN_ALLOW_THREADS
            bool cppResult = cppSelf->waitForEncrypted(cppArg0);
            PyEval_RestoreThread(_save); // Py_END_ALLOW_THREADS
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_waitForEncrypted_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_waitForReadyRead(PyObject *self, PyObject *args, PyObject *kwds)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.waitForReadyRead";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths
    if (numArgs > 1) {
        static PyObject *const too_many = Shiboken::String::createStaticString(">");
        errInfo.reset(too_many);
        Py_INCREF(errInfo.object());
        goto Sbk_QSslSocketFunc_waitForReadyRead_TypeError;
    }

    if (!PyArg_ParseTuple(args, "|O:waitForReadyRead", &(pyArgs[0])))
        return {};


    // Overloaded function decisor
    // 0: QIODevice::waitForReadyRead(int)->bool
    if (numArgs == 0) {
        overloadId = 0; // waitForReadyRead(int)
    } else if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[0])))) {
        overloadId = 0; // waitForReadyRead(int)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_waitForReadyRead_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_msecs = Shiboken::String::createStaticString("msecs");
            if (PyDict_Contains(kwds, key_msecs)) {
                value = PyDict_GetItem(kwds, key_msecs);
                if (value && pyArgs[0]) {
                    errInfo.reset(key_msecs);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QSslSocketFunc_waitForReadyRead_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<int>(), (pyArgs[0]))))
                        goto Sbk_QSslSocketFunc_waitForReadyRead_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_msecs);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                goto Sbk_QSslSocketFunc_waitForReadyRead_TypeError;
            }
        }
        int cppArg0 = 30000;
        if (pythonToCpp[0])
            pythonToCpp[0](pyArgs[0], &cppArg0);

        if (!PyErr_Occurred()) {
            // waitForReadyRead(int)
            bool cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::waitForReadyRead(cppArg0)
                : cppSelf->waitForReadyRead(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_waitForReadyRead_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QSslSocketFunc_writeData(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QSslSocket.writeData";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0};

    // invalid argument lengths


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


    // Overloaded function decisor
    // 0: QIODevice::writeData(const char*,qint64)->qint64
    if (numArgs == 2
        && Shiboken::String::check(pyArgs[0]) && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<const char *>(), (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), (pyArgs[1])))) {
        overloadId = 0; // writeData(const char*,qint64)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QSslSocketFunc_writeData_TypeError;

    // Call function/method
    {
        const char* cppArg0;
        pythonToCpp[0](pyArgs[0], &cppArg0);
        qint64 cppArg1;
        pythonToCpp[1](pyArgs[1], &cppArg1);

        if (!PyErr_Occurred()) {
            // writeData(const char*,qint64)
            qint64 cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QSslSocket::writeData(cppArg0, cppArg1)
                : cppSelf->writeData(cppArg0, cppArg1);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<qint64>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QSslSocketFunc_writeData_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}


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

static PyMethodDef Sbk_QSslSocket_methods[] = {
    {"activeBackend", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_activeBackend), METH_NOARGS|METH_STATIC},
    {"atEnd", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_atEnd), METH_NOARGS},
    {"availableBackends", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_availableBackends), METH_NOARGS|METH_STATIC},
    {"bytesAvailable", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_bytesAvailable), METH_NOARGS},
    {"bytesToWrite", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_bytesToWrite), METH_NOARGS},
    {"canReadLine", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_canReadLine), METH_NOARGS},
    {"close", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_close), METH_NOARGS},
    {"connectToHost", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_connectToHost), METH_VARARGS|METH_KEYWORDS},
    {"connectToHostEncrypted", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_connectToHostEncrypted), METH_VARARGS|METH_KEYWORDS},
    {"continueInterruptedHandshake", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_continueInterruptedHandshake), METH_NOARGS},
    {"disconnectFromHost", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_disconnectFromHost), METH_NOARGS},
    {"encryptedBytesAvailable", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_encryptedBytesAvailable), METH_NOARGS},
    {"encryptedBytesToWrite", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_encryptedBytesToWrite), METH_NOARGS},
    {"ignoreSslErrors", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_ignoreSslErrors), METH_VARARGS},
    {"implementedClasses", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_implementedClasses), METH_VARARGS|METH_KEYWORDS|METH_STATIC},
    {"isClassImplemented", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_isClassImplemented), METH_VARARGS|METH_KEYWORDS|METH_STATIC},
    {"isEncrypted", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_isEncrypted), METH_NOARGS},
    {"isFeatureSupported", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_isFeatureSupported), METH_VARARGS|METH_KEYWORDS|METH_STATIC},
    {"isProtocolSupported", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_isProtocolSupported), METH_VARARGS|METH_KEYWORDS|METH_STATIC},
    {"localCertificate", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_localCertificate), METH_NOARGS},
    {"localCertificateChain", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_localCertificateChain), METH_NOARGS},
    {"mode", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_mode), METH_NOARGS},
    {"ocspResponses", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_ocspResponses), METH_NOARGS},
    {"peerCertificate", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_peerCertificate), METH_NOARGS},
    {"peerCertificateChain", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_peerCertificateChain), METH_NOARGS},
    {"peerVerifyDepth", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_peerVerifyDepth), METH_NOARGS},
    {"peerVerifyMode", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_peerVerifyMode), METH_NOARGS},
    {"peerVerifyName", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_peerVerifyName), METH_NOARGS},
    {"privateKey", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_privateKey), METH_NOARGS},
    {"protocol", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_protocol), METH_NOARGS},
    {"readData", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_readData), METH_O},
    {"resume", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_resume), METH_NOARGS},
    {"sessionCipher", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_sessionCipher), METH_NOARGS},
    {"sessionProtocol", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_sessionProtocol), METH_NOARGS},
    {"setActiveBackend", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setActiveBackend), METH_O|METH_STATIC},
    {"setLocalCertificate", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setLocalCertificate), METH_VARARGS|METH_KEYWORDS},
    {"setLocalCertificateChain", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setLocalCertificateChain), METH_O},
    {"setPeerVerifyDepth", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setPeerVerifyDepth), METH_O},
    {"setPeerVerifyMode", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setPeerVerifyMode), METH_O},
    {"setPeerVerifyName", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setPeerVerifyName), METH_O},
    {"setPrivateKey", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setPrivateKey), METH_VARARGS|METH_KEYWORDS},
    {"setProtocol", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setProtocol), METH_O},
    {"setReadBufferSize", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setReadBufferSize), METH_O},
    {"setSocketDescriptor", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setSocketDescriptor), METH_VARARGS|METH_KEYWORDS},
    {"setSocketOption", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setSocketOption), METH_VARARGS},
    {"setSslConfiguration", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_setSslConfiguration), METH_O},
    {"skipData", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_skipData), METH_O},
    {"socketOption", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_socketOption), METH_O},
    {"sslConfiguration", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_sslConfiguration), METH_NOARGS},
    {"sslHandshakeErrors", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_sslHandshakeErrors), METH_NOARGS},
    {"sslLibraryBuildVersionNumber", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_sslLibraryBuildVersionNumber), METH_NOARGS|METH_STATIC},
    {"sslLibraryBuildVersionString", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_sslLibraryBuildVersionString), METH_NOARGS|METH_STATIC},
    {"sslLibraryVersionNumber", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_sslLibraryVersionNumber), METH_NOARGS|METH_STATIC},
    {"sslLibraryVersionString", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_sslLibraryVersionString), METH_NOARGS|METH_STATIC},
    {"startClientEncryption", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_startClientEncryption), METH_NOARGS},
    {"startServerEncryption", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_startServerEncryption), METH_NOARGS},
    {"supportedFeatures", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_supportedFeatures), METH_VARARGS|METH_KEYWORDS|METH_STATIC},
    {"supportedProtocols", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_supportedProtocols), METH_VARARGS|METH_KEYWORDS|METH_STATIC},
    {"supportsSsl", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_supportsSsl), METH_NOARGS|METH_STATIC},
    {"waitForBytesWritten", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_waitForBytesWritten), METH_VARARGS|METH_KEYWORDS},
    {"waitForConnected", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_waitForConnected), METH_VARARGS|METH_KEYWORDS},
    {"waitForDisconnected", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_waitForDisconnected), METH_VARARGS|METH_KEYWORDS},
    {"waitForEncrypted", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_waitForEncrypted), METH_VARARGS|METH_KEYWORDS},
    {"waitForReadyRead", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_waitForReadyRead), METH_VARARGS|METH_KEYWORDS},
    {"writeData", reinterpret_cast<PyCFunction>(Sbk_QSslSocketFunc_writeData), METH_VARARGS},

    {nullptr, nullptr} // Sentinel
};

static int Sbk_QSslSocket_setattro(PyObject *self, PyObject *name, PyObject *value)
{
    PySide::Feature::Select(self);
    if (value && PyCallable_Check(value)) {
        auto plain_inst = reinterpret_cast< ::QSslSocket *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX], reinterpret_cast<SbkObject *>(self)));
        auto inst = dynamic_cast<QSslSocketWrapper *>(plain_inst);
        if (inst)
            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_QSslSocket_traverse(PyObject *self, visitproc visit, void *arg)
{
    return SbkObject_TypeF()->tp_traverse(self, visit, arg);
}
static int Sbk_QSslSocket_clear(PyObject *self)
{
    return reinterpret_cast<PyTypeObject *>(SbkObject_TypeF())->tp_clear(self);
}
static void * Sbk_QSslSocketSpecialCastFunction(void *obj, PyTypeObject *desiredType)
{
    auto me = reinterpret_cast< ::QSslSocket *>(obj);
    if (desiredType == SbkPySide6_QtNetworkTypes[SBK_QTCPSOCKET_IDX])
        return static_cast< ::QTcpSocket *>(me);
    else if (desiredType == SbkPySide6_QtNetworkTypes[SBK_QABSTRACTSOCKET_IDX])
        return static_cast< ::QAbstractSocket *>(me);
    else if (desiredType == SbkPySide6_QtCoreTypes[SBK_QIODEVICE_IDX])
        return static_cast< ::QIODevice *>(me);
    else if (desiredType == SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX])
        return static_cast< ::QObject *>(me);
    else if (desiredType == SbkPySide6_QtCoreTypes[SBK_QIODEVICEBASE_IDX])
        return static_cast< ::QIODeviceBase *>(me);
    return me;
}


// Class Definition -----------------------------------------------
extern "C" {
static PyTypeObject *_Sbk_QSslSocket_Type = nullptr;
static PyTypeObject *Sbk_QSslSocket_TypeF(void)
{
    return _Sbk_QSslSocket_Type;
}

static PyType_Slot Sbk_QSslSocket_slots[] = {
    {Py_tp_base,        nullptr}, // inserted by introduceWrapperType
    {Py_tp_dealloc,     reinterpret_cast<void *>(&SbkDeallocWrapper)},
    {Py_tp_repr,        nullptr},
    {Py_tp_hash,        nullptr},
    {Py_tp_call,        nullptr},
    {Py_tp_str,         nullptr},
    {Py_tp_getattro,    nullptr},
    {Py_tp_setattro,    reinterpret_cast<void *>(Sbk_QSslSocket_setattro)},
    {Py_tp_traverse,    reinterpret_cast<void *>(Sbk_QSslSocket_traverse)},
    {Py_tp_clear,       reinterpret_cast<void *>(Sbk_QSslSocket_clear)},
    {Py_tp_richcompare, nullptr},
    {Py_tp_iter,        nullptr},
    {Py_tp_iternext,    nullptr},
    {Py_tp_methods,     reinterpret_cast<void *>(Sbk_QSslSocket_methods)},
    {Py_tp_getset,      nullptr},
    {Py_tp_init,        reinterpret_cast<void *>(Sbk_QSslSocket_Init)},
    {Py_tp_new,         reinterpret_cast<void *>(SbkObjectTpNew)},
    {0, nullptr}
};
static PyType_Spec Sbk_QSslSocket_spec = {
    "2:PySide6.QtNetwork.QSslSocket",
    sizeof(SbkObject),
    0,
    Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
    Sbk_QSslSocket_slots
};

} //extern "C"

static void *Sbk_QSslSocket_typeDiscovery(void *cptr, PyTypeObject *instanceType)
{
    if (instanceType == Shiboken::SbkType< ::QObject >())
        return dynamic_cast< ::QSslSocket *>(reinterpret_cast< ::QObject *>(cptr));
    return {};
}


// Type conversion functions.

// Python to C++ enum conversion.
static void QSslSocket_SslMode_PythonToCpp_QSslSocket_SslMode(PyObject *pyIn, void *cppOut)
{
    *reinterpret_cast<::QSslSocket::SslMode *>(cppOut) =
        static_cast<::QSslSocket::SslMode>(Shiboken::Enum::getValue(pyIn));

}
static PythonToCppFunc is_QSslSocket_SslMode_PythonToCpp_QSslSocket_SslMode_Convertible(PyObject *pyIn)
{
    if (PyObject_TypeCheck(pyIn, SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_SSLMODE_IDX]))
        return QSslSocket_SslMode_PythonToCpp_QSslSocket_SslMode;
    return {};
}
static PyObject *QSslSocket_SslMode_CppToPython_QSslSocket_SslMode(const void *cppIn)
{
    const int castCppIn = int(*reinterpret_cast<const ::QSslSocket::SslMode *>(cppIn));
    return Shiboken::Enum::newItem(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_SSLMODE_IDX], castCppIn);

}

static void QSslSocket_PeerVerifyMode_PythonToCpp_QSslSocket_PeerVerifyMode(PyObject *pyIn, void *cppOut)
{
    *reinterpret_cast<::QSslSocket::PeerVerifyMode *>(cppOut) =
        static_cast<::QSslSocket::PeerVerifyMode>(Shiboken::Enum::getValue(pyIn));

}
static PythonToCppFunc is_QSslSocket_PeerVerifyMode_PythonToCpp_QSslSocket_PeerVerifyMode_Convertible(PyObject *pyIn)
{
    if (PyObject_TypeCheck(pyIn, SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX]))
        return QSslSocket_PeerVerifyMode_PythonToCpp_QSslSocket_PeerVerifyMode;
    return {};
}
static PyObject *QSslSocket_PeerVerifyMode_CppToPython_QSslSocket_PeerVerifyMode(const void *cppIn)
{
    const int castCppIn = int(*reinterpret_cast<const ::QSslSocket::PeerVerifyMode *>(cppIn));
    return Shiboken::Enum::newItem(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX], castCppIn);

}

// Python to C++ pointer conversion - returns the C++ object of the Python wrapper (keeps object identity).
static void QSslSocket_PythonToCpp_QSslSocket_PTR(PyObject *pyIn, void *cppOut)
{
    Shiboken::Conversions::pythonToCppPointer(Sbk_QSslSocket_TypeF(), pyIn, cppOut);
}
static PythonToCppFunc is_QSslSocket_PythonToCpp_QSslSocket_PTR_Convertible(PyObject *pyIn)
{
    if (pyIn == Py_None)
        return Shiboken::Conversions::nonePythonToCppNullPtr;
    if (PyObject_TypeCheck(pyIn, reinterpret_cast<PyTypeObject *>(Sbk_QSslSocket_TypeF())))
        return QSslSocket_PythonToCpp_QSslSocket_PTR;
    return {};
}

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

}

// The signatures string for the functions.
// Multiple signatures have their index "n:" in front.
static const char *QSslSocket_SignatureStrings[] = {
    "PySide6.QtNetwork.QSslSocket(self,parent:PySide6.QtCore.QObject=nullptr)",
    "PySide6.QtNetwork.QSslSocket.activeBackend()->QString",
    "PySide6.QtNetwork.QSslSocket.atEnd(self)->bool",
    "PySide6.QtNetwork.QSslSocket.availableBackends()->QList[QString]",
    "PySide6.QtNetwork.QSslSocket.bytesAvailable(self)->qint64",
    "PySide6.QtNetwork.QSslSocket.bytesToWrite(self)->qint64",
    "PySide6.QtNetwork.QSslSocket.canReadLine(self)->bool",
    "PySide6.QtNetwork.QSslSocket.close(self)",
    "1:PySide6.QtNetwork.QSslSocket.connectToHost(self,hostName:QString,port:quint16,openMode:PySide6.QtCore.QIODeviceBase.OpenMode=QIODeviceBase.OpenModeFlag.ReadWrite,protocol:PySide6.QtNetwork.QAbstractSocket.NetworkLayerProtocol=QAbstractSocket.NetworkLayerProtocol.AnyIPProtocol)",
    "0:PySide6.QtNetwork.QSslSocket.connectToHost(self,address:typing.Union[PySide6.QtNetwork.QHostAddress, PySide6.QtNetwork.QHostAddress.SpecialAddress],port:quint16,mode:PySide6.QtCore.QIODeviceBase.OpenMode=QIODeviceBase.OpenModeFlag.ReadWrite)",
    "1:PySide6.QtNetwork.QSslSocket.connectToHostEncrypted(self,hostName:QString,port:quint16,mode:PySide6.QtCore.QIODeviceBase.OpenMode=QIODeviceBase.OpenModeFlag.ReadWrite,protocol:PySide6.QtNetwork.QAbstractSocket.NetworkLayerProtocol=QAbstractSocket.NetworkLayerProtocol.AnyIPProtocol)",
    "0:PySide6.QtNetwork.QSslSocket.connectToHostEncrypted(self,hostName:QString,port:quint16,sslPeerName:QString,mode:PySide6.QtCore.QIODeviceBase.OpenMode=QIODeviceBase.OpenModeFlag.ReadWrite,protocol:PySide6.QtNetwork.QAbstractSocket.NetworkLayerProtocol=QAbstractSocket.NetworkLayerProtocol.AnyIPProtocol)",
    "PySide6.QtNetwork.QSslSocket.continueInterruptedHandshake(self)",
    "PySide6.QtNetwork.QSslSocket.disconnectFromHost(self)",
    "PySide6.QtNetwork.QSslSocket.encryptedBytesAvailable(self)->qint64",
    "PySide6.QtNetwork.QSslSocket.encryptedBytesToWrite(self)->qint64",
    "1:PySide6.QtNetwork.QSslSocket.ignoreSslErrors(self)",
    "0:PySide6.QtNetwork.QSslSocket.ignoreSslErrors(self,errors:QList[PySide6.QtNetwork.QSslError])",
    "PySide6.QtNetwork.QSslSocket.implementedClasses(backendName:QString={})->QList[PySide6.QtNetwork.QSsl.ImplementedClass]",
    "PySide6.QtNetwork.QSslSocket.isClassImplemented(cl:PySide6.QtNetwork.QSsl.ImplementedClass,backendName:QString={})->bool",
    "PySide6.QtNetwork.QSslSocket.isEncrypted(self)->bool",
    "PySide6.QtNetwork.QSslSocket.isFeatureSupported(feat:PySide6.QtNetwork.QSsl.SupportedFeature,backendName:QString={})->bool",
    "PySide6.QtNetwork.QSslSocket.isProtocolSupported(protocol:PySide6.QtNetwork.QSsl.SslProtocol,backendName:QString={})->bool",
    "PySide6.QtNetwork.QSslSocket.localCertificate(self)->PySide6.QtNetwork.QSslCertificate",
    "PySide6.QtNetwork.QSslSocket.localCertificateChain(self)->QList[PySide6.QtNetwork.QSslCertificate]",
    "PySide6.QtNetwork.QSslSocket.mode(self)->PySide6.QtNetwork.QSslSocket.SslMode",
    "PySide6.QtNetwork.QSslSocket.ocspResponses(self)->QList[PySide6.QtNetwork.QOcspResponse]",
    "PySide6.QtNetwork.QSslSocket.peerCertificate(self)->PySide6.QtNetwork.QSslCertificate",
    "PySide6.QtNetwork.QSslSocket.peerCertificateChain(self)->QList[PySide6.QtNetwork.QSslCertificate]",
    "PySide6.QtNetwork.QSslSocket.peerVerifyDepth(self)->int",
    "PySide6.QtNetwork.QSslSocket.peerVerifyMode(self)->PySide6.QtNetwork.QSslSocket.PeerVerifyMode",
    "PySide6.QtNetwork.QSslSocket.peerVerifyName(self)->QString",
    "PySide6.QtNetwork.QSslSocket.privateKey(self)->PySide6.QtNetwork.QSslKey",
    "PySide6.QtNetwork.QSslSocket.protocol(self)->PySide6.QtNetwork.QSsl.SslProtocol",
    "PySide6.QtNetwork.QSslSocket.readData(self,data:char*,maxlen:qint64)->PyObject",
    "PySide6.QtNetwork.QSslSocket.resume(self)",
    "PySide6.QtNetwork.QSslSocket.sessionCipher(self)->PySide6.QtNetwork.QSslCipher",
    "PySide6.QtNetwork.QSslSocket.sessionProtocol(self)->PySide6.QtNetwork.QSsl.SslProtocol",
    "PySide6.QtNetwork.QSslSocket.setActiveBackend(backendName:QString)->bool",
    "1:PySide6.QtNetwork.QSslSocket.setLocalCertificate(self,certificate:typing.Union[PySide6.QtNetwork.QSslCertificate, PySide6.QtCore.QIODevice])",
    "0:PySide6.QtNetwork.QSslSocket.setLocalCertificate(self,fileName:QString,format:PySide6.QtNetwork.QSsl.EncodingFormat=QSsl.Pem)",
    "PySide6.QtNetwork.QSslSocket.setLocalCertificateChain(self,localChain:QList[PySide6.QtNetwork.QSslCertificate])",
    "PySide6.QtNetwork.QSslSocket.setPeerVerifyDepth(self,depth:int)",
    "PySide6.QtNetwork.QSslSocket.setPeerVerifyMode(self,mode:PySide6.QtNetwork.QSslSocket.PeerVerifyMode)",
    "PySide6.QtNetwork.QSslSocket.setPeerVerifyName(self,hostName:QString)",
    "1:PySide6.QtNetwork.QSslSocket.setPrivateKey(self,key:typing.Union[PySide6.QtNetwork.QSslKey, Qt.HANDLE])",
    "0:PySide6.QtNetwork.QSslSocket.setPrivateKey(self,fileName:QString,algorithm:PySide6.QtNetwork.QSsl.KeyAlgorithm=QSsl.Rsa,format:PySide6.QtNetwork.QSsl.EncodingFormat=QSsl.Pem,passPhrase:typing.Union[PySide6.QtCore.QByteArray, char*]=QByteArray())",
    "PySide6.QtNetwork.QSslSocket.setProtocol(self,protocol:PySide6.QtNetwork.QSsl.SslProtocol)",
    "PySide6.QtNetwork.QSslSocket.setReadBufferSize(self,size:qint64)",
    "PySide6.QtNetwork.QSslSocket.setSocketDescriptor(self,socketDescriptor:qintptr,state:PySide6.QtNetwork.QAbstractSocket.SocketState=QAbstractSocket.SocketState.ConnectedState,openMode:PySide6.QtCore.QIODeviceBase.OpenMode=QIODeviceBase.OpenModeFlag.ReadWrite)->bool",
    "PySide6.QtNetwork.QSslSocket.setSocketOption(self,option:PySide6.QtNetwork.QAbstractSocket.SocketOption,value:QVariant)",
    "PySide6.QtNetwork.QSslSocket.setSslConfiguration(self,config:PySide6.QtNetwork.QSslConfiguration)",
    "PySide6.QtNetwork.QSslSocket.skipData(self,maxSize:qint64)->qint64",
    "PySide6.QtNetwork.QSslSocket.socketOption(self,option:PySide6.QtNetwork.QAbstractSocket.SocketOption)->QVariant",
    "PySide6.QtNetwork.QSslSocket.sslConfiguration(self)->PySide6.QtNetwork.QSslConfiguration",
    "PySide6.QtNetwork.QSslSocket.sslHandshakeErrors(self)->QList[PySide6.QtNetwork.QSslError]",
    "PySide6.QtNetwork.QSslSocket.sslLibraryBuildVersionNumber()->long",
    "PySide6.QtNetwork.QSslSocket.sslLibraryBuildVersionString()->QString",
    "PySide6.QtNetwork.QSslSocket.sslLibraryVersionNumber()->long",
    "PySide6.QtNetwork.QSslSocket.sslLibraryVersionString()->QString",
    "PySide6.QtNetwork.QSslSocket.startClientEncryption(self)",
    "PySide6.QtNetwork.QSslSocket.startServerEncryption(self)",
    "PySide6.QtNetwork.QSslSocket.supportedFeatures(backendName:QString={})->QList[PySide6.QtNetwork.QSsl.SupportedFeature]",
    "PySide6.QtNetwork.QSslSocket.supportedProtocols(backendName:QString={})->QList[PySide6.QtNetwork.QSsl.SslProtocol]",
    "PySide6.QtNetwork.QSslSocket.supportsSsl()->bool",
    "PySide6.QtNetwork.QSslSocket.waitForBytesWritten(self,msecs:int=30000)->bool",
    "PySide6.QtNetwork.QSslSocket.waitForConnected(self,msecs:int=30000)->bool",
    "PySide6.QtNetwork.QSslSocket.waitForDisconnected(self,msecs:int=30000)->bool",
    "PySide6.QtNetwork.QSslSocket.waitForEncrypted(self,msecs:int=30000)->bool",
    "PySide6.QtNetwork.QSslSocket.waitForReadyRead(self,msecs:int=30000)->bool",
    "PySide6.QtNetwork.QSslSocket.writeData(self,data:char*,len:qint64)->qint64",
    nullptr}; // Sentinel

void init_QSslSocket(PyObject *module)
{
    _Sbk_QSslSocket_Type = Shiboken::ObjectType::introduceWrapperType(
        module,
        "QSslSocket",
        "QSslSocket*",
        &Sbk_QSslSocket_spec,
        &Shiboken::callCppDestructor< ::QSslSocket >,
        SbkPySide6_QtNetworkTypes[SBK_QTCPSOCKET_IDX],
        0,
        0);
    auto *pyType = Sbk_QSslSocket_TypeF(); // references _Sbk_QSslSocket_Type
    InitSignatureStrings(pyType, QSslSocket_SignatureStrings);
    SbkObjectType_SetPropertyStrings(reinterpret_cast<PyTypeObject *>(_Sbk_QSslSocket_Type), Sbk_QSslSocket_PropertyStrings);
    SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_IDX]
        = Sbk_QSslSocket_TypeF();

    // Register Converter
    SbkConverter *converter = Shiboken::Conversions::createConverter(Sbk_QSslSocket_TypeF(),
        QSslSocket_PythonToCpp_QSslSocket_PTR,
        is_QSslSocket_PythonToCpp_QSslSocket_PTR_Convertible,
        QSslSocket_PTR_CppToPython_QSslSocket);

    Shiboken::Conversions::registerConverterName(converter, "QSslSocket");
    Shiboken::Conversions::registerConverterName(converter, "QSslSocket*");
    Shiboken::Conversions::registerConverterName(converter, "QSslSocket&");
    Shiboken::Conversions::registerConverterName(converter, typeid(::QSslSocket).name());
    Shiboken::Conversions::registerConverterName(converter, typeid(::QSslSocketWrapper).name());


    MultipleInheritanceInitFunction func = Shiboken::ObjectType::getMultipleInheritanceFunction(SbkPySide6_QtCoreTypes[SBK_QIODEVICE_IDX]);
    Shiboken::ObjectType::setMultipleInheritanceFunction(Sbk_QSslSocket_TypeF(), func);
    Shiboken::ObjectType::setCastFunction(Sbk_QSslSocket_TypeF(), &Sbk_QSslSocketSpecialCastFunction);
    Shiboken::ObjectType::setTypeDiscoveryFunctionV2(Sbk_QSslSocket_TypeF(), &Sbk_QSslSocket_typeDiscovery);

    // Initialization of enums.

    // Initialization of enum 'SslMode'.
    SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_SSLMODE_IDX] = Shiboken::Enum::createScopedEnum(Sbk_QSslSocket_TypeF(),
        "SslMode",
        "2:PySide6.QtNetwork.QSslSocket.SslMode",
        "QSslSocket::SslMode");
    if (!SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_SSLMODE_IDX])
        return;

    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_SSLMODE_IDX],
        Sbk_QSslSocket_TypeF(), "UnencryptedMode", (long) QSslSocket::SslMode::UnencryptedMode))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_SSLMODE_IDX],
        Sbk_QSslSocket_TypeF(), "SslClientMode", (long) QSslSocket::SslMode::SslClientMode))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_SSLMODE_IDX],
        Sbk_QSslSocket_TypeF(), "SslServerMode", (long) QSslSocket::SslMode::SslServerMode))
        return;
    // Register converter for enum 'QSslSocket::SslMode'.
    {
        SbkConverter *converter = Shiboken::Conversions::createConverter(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_SSLMODE_IDX],
            QSslSocket_SslMode_CppToPython_QSslSocket_SslMode);
        Shiboken::Conversions::addPythonToCppValueConversion(converter,
            QSslSocket_SslMode_PythonToCpp_QSslSocket_SslMode,
            is_QSslSocket_SslMode_PythonToCpp_QSslSocket_SslMode_Convertible);
        Shiboken::Enum::setTypeConverter(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_SSLMODE_IDX], converter, false);
        Shiboken::Conversions::registerConverterName(converter, "QSslSocket::SslMode");
        Shiboken::Conversions::registerConverterName(converter, "SslMode");
    }
    // End of 'SslMode' enum.

    // Initialization of enum 'PeerVerifyMode'.
    SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX] = Shiboken::Enum::createScopedEnum(Sbk_QSslSocket_TypeF(),
        "PeerVerifyMode",
        "2:PySide6.QtNetwork.QSslSocket.PeerVerifyMode",
        "QSslSocket::PeerVerifyMode");
    if (!SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX])
        return;

    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX],
        Sbk_QSslSocket_TypeF(), "VerifyNone", (long) QSslSocket::PeerVerifyMode::VerifyNone))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX],
        Sbk_QSslSocket_TypeF(), "QueryPeer", (long) QSslSocket::PeerVerifyMode::QueryPeer))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX],
        Sbk_QSslSocket_TypeF(), "VerifyPeer", (long) QSslSocket::PeerVerifyMode::VerifyPeer))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX],
        Sbk_QSslSocket_TypeF(), "AutoVerifyPeer", (long) QSslSocket::PeerVerifyMode::AutoVerifyPeer))
        return;
    // Register converter for enum 'QSslSocket::PeerVerifyMode'.
    {
        SbkConverter *converter = Shiboken::Conversions::createConverter(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX],
            QSslSocket_PeerVerifyMode_CppToPython_QSslSocket_PeerVerifyMode);
        Shiboken::Conversions::addPythonToCppValueConversion(converter,
            QSslSocket_PeerVerifyMode_PythonToCpp_QSslSocket_PeerVerifyMode,
            is_QSslSocket_PeerVerifyMode_PythonToCpp_QSslSocket_PeerVerifyMode_Convertible);
        Shiboken::Enum::setTypeConverter(SbkPySide6_QtNetworkTypes[SBK_QSSLSOCKET_PEERVERIFYMODE_IDX], converter, false);
        Shiboken::Conversions::registerConverterName(converter, "QSslSocket::PeerVerifyMode");
        Shiboken::Conversions::registerConverterName(converter, "PeerVerifyMode");
    }
    // End of 'PeerVerifyMode' enum.

    PySide::Signal::registerSignals(Sbk_QSslSocket_TypeF(), &::QSslSocket::staticMetaObject);
    qRegisterMetaType< ::QSslSocket::SslMode >("QSslSocket::SslMode");
    qRegisterMetaType< ::QSslSocket::PeerVerifyMode >("QSslSocket::PeerVerifyMode");
    Shiboken::ObjectType::setSubTypeInitHook(Sbk_QSslSocket_TypeF(), &PySide::initQObjectSubType);
    PySide::initDynamicMetaObject(Sbk_QSslSocket_TypeF(), &::QSslSocket::staticMetaObject, sizeof(QSslSocketWrapper));
}
