/****************************************************************************
**
** 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 "qnetworkreply_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 QNetworkReplyWrapper::resetPyMethodCache()
{
    std::fill_n(m_PyMethodCache, sizeof(m_PyMethodCache) / sizeof(m_PyMethodCache[0]), false);
}

QNetworkReplyWrapper::QNetworkReplyWrapper(QObject * parent) : QNetworkReply(parent)
{
    resetPyMethodCache();
    // ... middle
}

void QNetworkReplyWrapper::abort()
{
    if (m_PyMethodCache[0]) {
        PyErr_SetString(PyExc_NotImplementedError, "pure virtual method 'QNetworkReply.abort()' not implemented.");
        return;
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "abort";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[0] = true;
        PyErr_SetString(PyExc_NotImplementedError, "pure virtual method 'QNetworkReply.abort()' not implemented.");
        return;
    }

    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 QNetworkReplyWrapper::atEnd() const
{
    if (m_PyMethodCache[1])
        return this->::QIODevice::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[1] = true;
        return this->::QIODevice::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.",
            "QNetworkReply.atEnd",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QNetworkReplyWrapper::bytesAvailable() const
{
    if (m_PyMethodCache[2])
        return this->::QIODevice::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[2] = true;
        return this->::QIODevice::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.",
            "QNetworkReply.bytesAvailable",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QNetworkReplyWrapper::bytesToWrite() const
{
    if (m_PyMethodCache[3])
        return this->::QIODevice::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[3] = true;
        return this->::QIODevice::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.",
            "QNetworkReply.bytesToWrite",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QNetworkReplyWrapper::canReadLine() const
{
    if (m_PyMethodCache[4])
        return this->::QIODevice::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[4] = true;
        return this->::QIODevice::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.",
            "QNetworkReply.canReadLine",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

void QNetworkReplyWrapper::childEvent(QChildEvent * event)
{
    if (m_PyMethodCache[5]) {
        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[5] = 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 QNetworkReplyWrapper::close()
{
    if (m_PyMethodCache[6]) {
        return this->::QNetworkReply::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[6] = true;
        return this->::QNetworkReply::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 QNetworkReplyWrapper::connectNotify(const QMetaMethod & signal)
{
    if (m_PyMethodCache[7]) {
        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[7] = 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 QNetworkReplyWrapper::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 QNetworkReplyWrapper::disconnectNotify(const QMetaMethod & signal)
{
    if (m_PyMethodCache[9]) {
        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[9] = 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 QNetworkReplyWrapper::event(QEvent * event)
{
    if (m_PyMethodCache[10])
        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[10] = 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.",
            "QNetworkReply.event",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QNetworkReplyWrapper::eventFilter(QObject * watched, QEvent * event)
{
    if (m_PyMethodCache[11])
        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[11] = 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.",
            "QNetworkReply.eventFilter",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

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

    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 QNetworkReplyWrapper::ignoreSslErrorsImplementation(const QList<QSslError > & arg__1)
{
    if (m_PyMethodCache[13]) {
        return this->::QNetworkReply::ignoreSslErrorsImplementation(arg__1);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "ignoreSslErrorsImplementation";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[13] = true;
        return this->::QNetworkReply::ignoreSslErrorsImplementation(arg__1);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QSSLERROR_IDX], &arg__1)
    ));

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

bool QNetworkReplyWrapper::isSequential() const
{
    if (m_PyMethodCache[14])
        return this->::QNetworkReply::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[14] = true;
        return this->::QNetworkReply::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.",
            "QNetworkReply.isSequential",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QNetworkReplyWrapper::open(QFlags<QIODeviceBase::OpenModeFlag> mode)
{
    if (m_PyMethodCache[16])
        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[16] = 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.",
            "QNetworkReply.open",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QNetworkReplyWrapper::pos() const
{
    if (m_PyMethodCache[17])
        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[17] = 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.",
            "QNetworkReply.pos",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QNetworkReplyWrapper::readData(char * data, qint64 maxlen)
{
    if (m_PyMethodCache[18]) {
        PyErr_SetString(PyExc_NotImplementedError, "pure virtual method 'QNetworkReply.readData()' not implemented.");
        return 0;
    }
    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[18] = true;
        PyErr_SetString(PyExc_NotImplementedError, "pure virtual method 'QNetworkReply.readData()' not implemented.");
        return 0;
    }

    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 QNetworkReplyWrapper::readLineData(char * data, qint64 maxlen)
{
    if (m_PyMethodCache[19]) {
        return this->::QIODevice::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[19] = true;
        return this->::QIODevice::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 QNetworkReplyWrapper::reset()
{
    if (m_PyMethodCache[20])
        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[20] = 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.",
            "QNetworkReply.reset",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QNetworkReplyWrapper::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.",
            "QNetworkReply.seek",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

void QNetworkReplyWrapper::setReadBufferSize(qint64 size)
{
    if (m_PyMethodCache[22]) {
        return this->::QNetworkReply::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->::QNetworkReply::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;
    }
}

void QNetworkReplyWrapper::setSslConfigurationImplementation(const QSslConfiguration & arg__1)
{
    if (m_PyMethodCache[23]) {
        return this->::QNetworkReply::setSslConfigurationImplementation(arg__1);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "setSslConfigurationImplementation";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[23] = true;
        return this->::QNetworkReply::setSslConfigurationImplementation(arg__1);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypes[SBK_QSSLCONFIGURATION_IDX], &arg__1)
    ));

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

qint64 QNetworkReplyWrapper::size() const
{
    if (m_PyMethodCache[24])
        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[24] = 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.",
            "QNetworkReply.size",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QNetworkReplyWrapper::skipData(qint64 maxSize)
{
    if (m_PyMethodCache[25])
        return this->::QIODevice::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[25] = true;
        return this->::QIODevice::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.",
            "QNetworkReply.skipData",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

void QNetworkReplyWrapper::sslConfigurationImplementation(QSslConfiguration & arg__1) const
{
    if (m_PyMethodCache[26]) {
        return this->::QNetworkReply::sslConfigurationImplementation(arg__1);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "sslConfigurationImplementation";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[26] = true;
        return this->::QNetworkReply::sslConfigurationImplementation(arg__1);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::referenceToPython(SbkPySide6_QtNetworkTypes[SBK_QSSLCONFIGURATION_IDX], &arg__1)
    ));

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

void QNetworkReplyWrapper::timerEvent(QTimerEvent * event)
{
    if (m_PyMethodCache[27]) {
        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[27] = 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 QNetworkReplyWrapper::waitForBytesWritten(int msecs)
{
    if (m_PyMethodCache[28])
        return this->::QIODevice::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[28] = true;
        return this->::QIODevice::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.",
            "QNetworkReply.waitForBytesWritten",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QNetworkReplyWrapper::waitForReadyRead(int msecs)
{
    if (m_PyMethodCache[29])
        return this->::QIODevice::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[29] = true;
        return this->::QIODevice::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.",
            "QNetworkReply.waitForReadyRead",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

qint64 QNetworkReplyWrapper::writeData(const char * data, qint64 len)
{
    if (m_PyMethodCache[30])
        return this->::QNetworkReply::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[30] = true;
        return this->::QNetworkReply::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.",
            "QNetworkReply.writeData",
            "qint64",
            Py_TYPE(pyResult)->tp_name);
        return 0;
    }
    qint64 cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

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

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

void *QNetworkReplyWrapper::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< QNetworkReplyWrapper *>(this));
    return QNetworkReply::qt_metacast(_clname);
}

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

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

extern "C" {
static int
Sbk_QNetworkReply_Init(PyObject *self, PyObject *args, PyObject *kwds)
{
    const QMetaObject *metaObject;
    SbkObject *sbkSelf = reinterpret_cast<SbkObject *>(self);
    PyTypeObject *type = self->ob_type;
    PyTypeObject *myType = SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_IDX];
    if (type == myType) {
        PyErr_SetString(PyExc_NotImplementedError,
            "'QNetworkReply' represents a C++ abstract class and cannot be instantiated");
        return -1;
    }

    PySide::Feature::Select(self);
    if (Shiboken::Object::isUserType(self) && !Shiboken::ObjectType::canCallConstructor(self->ob_type, Shiboken::SbkType< ::QNetworkReply >()))
        return -1;

    ::QNetworkReplyWrapper *cptr{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QNetworkReply.__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:QNetworkReply", &(pyArgs[0])))
        return -1;


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

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QNetworkReply_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_QNetworkReply_Init_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], (pyArgs[0]))))
                        goto Sbk_QNetworkReply_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()) {
            // QNetworkReply(QObject*)
            void *addr = PySide::nextQObjectMemoryAddr();
            if (addr) {
                cptr = new (addr) ::QNetworkReplyWrapper(cppArg0);
                PySide::setNextQObjectMemoryAddr(0);
            } else {
                cptr = new ::QNetworkReplyWrapper(cppArg0);
            }

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

    if (PyErr_Occurred() || !Shiboken::Object::setCppPointer(sbkSelf, Shiboken::SbkType< ::QNetworkReply >(), cptr)) {
        delete cptr;
        return -1;
    }
    if (!cptr) goto Sbk_QNetworkReply_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_QNetworkReply_Init_TypeError;
    };


    return 1;

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

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

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // abort()
            if (Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))) {
                PyErr_SetString(PyExc_NotImplementedError, "pure virtual method 'QNetworkReply.abort()' not implemented.");
                return {};
            }
            cppSelf->abort();
        }
    }

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

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

    // Overloaded function decisor
    // 0: QNetworkReply::attribute(QNetworkRequest::Attribute)const->QVariant
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREQUEST_ATTRIBUTE_IDX]))->converter, (pyArg)))) {
        overloadId = 0; // attribute(QNetworkRequest::Attribute)const
    }

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

    // Call function/method
    {
        ::QNetworkRequest::Attribute cppArg0{QNetworkRequest::HttpStatusCodeAttribute};
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // attribute(QNetworkRequest::Attribute)const
            QVariant cppResult = const_cast<const ::QNetworkReply *>(cppSelf)->attribute(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QVARIANT_IDX], &cppResult);
        }
    }

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

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

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

    // Call function/method
    {

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

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

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

    // Call function/method
    {

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

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

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

    // Overloaded function decisor
    // 0: QNetworkReply::hasRawHeader(QByteArray)const->bool
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QBYTEARRAY_IDX], (pyArg)))) {
        overloadId = 0; // hasRawHeader(QByteArray)const
    }

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

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


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

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

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

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

    // Overloaded function decisor
    // 0: QNetworkReply::header(QNetworkRequest::KnownHeaders)const->QVariant
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREQUEST_KNOWNHEADERS_IDX]))->converter, (pyArg)))) {
        overloadId = 0; // header(QNetworkRequest::KnownHeaders)const
    }

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

    // Call function/method
    {
        ::QNetworkRequest::KnownHeaders cppArg0{QNetworkRequest::ContentTypeHeader};
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // header(QNetworkRequest::KnownHeaders)const
            QVariant cppResult = const_cast<const ::QNetworkReply *>(cppSelf)->header(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QVARIANT_IDX], &cppResult);
        }
    }

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

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

static PyObject *Sbk_QNetworkReplyFunc_ignoreSslErrors(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QNetworkReply *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QNetworkReply.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: QNetworkReply::ignoreSslErrors()
    // 1: QNetworkReply::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_QNetworkReplyFunc_ignoreSslErrors_TypeError;

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

            if (!PyErr_Occurred()) {
                // ignoreSslErrors()
                Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                    ? cppSelf->::QNetworkReply::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_QNetworkReplyFunc_ignoreSslErrors_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

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

    // Overloaded function decisor
    // 0: QNetworkReply::ignoreSslErrorsImplementation(QList<QSslError>)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QSSLERROR_IDX], (pyArg)))) {
        overloadId = 0; // ignoreSslErrorsImplementation(QList<QSslError>)
    }

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

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

        if (!PyErr_Occurred()) {
            // ignoreSslErrorsImplementation(QList<QSslError>)
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QNetworkReply::ignoreSslErrorsImplementation(cppArg0)
                : cppSelf->ignoreSslErrorsImplementation(cppArg0);
        }
    }

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

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

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

    // Call function/method
    {

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

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

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

    // Call function/method
    {

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

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

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

    // Call function/method
    {

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

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

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

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // manager()const
            QNetworkAccessManager * cppResult = const_cast<const ::QNetworkReply *>(cppSelf)->manager();
            pyResult = Shiboken::Conversions::pointerToPython(SbkPySide6_QtNetworkTypes[SBK_QNETWORKACCESSMANAGER_IDX], cppResult);
            Shiboken::Object::setParent(self, pyResult);
        }
    }

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

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

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // operation()const
            QNetworkAccessManager::Operation cppResult = const_cast<const ::QNetworkReply *>(cppSelf)->operation();
            pyResult = Shiboken::Conversions::copyToPython(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QNETWORKACCESSMANAGER_OPERATION_IDX]))->converter, &cppResult);
        }
    }

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

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

    // Overloaded function decisor
    // 0: QNetworkReply::rawHeader(QByteArray)const->QByteArray
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QBYTEARRAY_IDX], (pyArg)))) {
        overloadId = 0; // rawHeader(QByteArray)const
    }

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

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


        if (!PyErr_Occurred()) {
            // rawHeader(QByteArray)const
            QByteArray cppResult = const_cast<const ::QNetworkReply *>(cppSelf)->rawHeader(*cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QBYTEARRAY_IDX], &cppResult);
        }
    }

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

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

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

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // rawHeaderList()const
            QList<QByteArray > cppResult = const_cast<const ::QNetworkReply *>(cppSelf)->rawHeaderList();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_QBYTEARRAY_IDX], &cppResult);
        }
    }

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

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

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // rawHeaderPairs()const
            const QList<std::pair< QByteArray,QByteArray > > & cppResult = const_cast<const ::QNetworkReply *>(cppSelf)->rawHeaderPairs();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypeConverters[SBK_QTNETWORK_QLIST_STD_PAIR_QBYTEARRAY_QBYTEARRAY_IDX], &cppResult);
        }
    }

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

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

    // Call function/method
    {

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

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

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

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // request()const
            QNetworkRequest cppResult = const_cast<const ::QNetworkReply *>(cppSelf)->request();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREQUEST_IDX], &cppResult);
        }
    }

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

static PyObject *Sbk_QNetworkReplyFunc_setAttribute(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QNetworkReply *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QNetworkReply.setAttribute";
    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, "setAttribute", 2, 2, &(pyArgs[0]), &(pyArgs[1])))
        return {};


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

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

    // Call function/method
    {
        ::QNetworkRequest::Attribute cppArg0{QNetworkRequest::HttpStatusCodeAttribute};
        pythonToCpp[0](pyArgs[0], &cppArg0);
        ::QVariant cppArg1;
        pythonToCpp[1](pyArgs[1], &cppArg1);

        if (!PyErr_Occurred()) {
            // setAttribute(QNetworkRequest::Attribute,QVariant)
            cppSelf->setAttribute(cppArg0, cppArg1);
        }
    }

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

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

static PyObject *Sbk_QNetworkReplyFunc_setError(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QNetworkReply *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QNetworkReply.setError";
    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, "setError", 2, 2, &(pyArgs[0]), &(pyArgs[1])))
        return {};


    // Overloaded function decisor
    // 0: QNetworkReply::setError(QNetworkReply::NetworkError,QString)
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX]))->converter, (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[1])))) {
        overloadId = 0; // setError(QNetworkReply::NetworkError,QString)
    }

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

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

        if (!PyErr_Occurred()) {
            // setError(QNetworkReply::NetworkError,QString)
            cppSelf->setError(cppArg0, cppArg1);
        }
    }

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

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

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

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

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

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

        if (!PyErr_Occurred()) {
            // setFinished(bool)
            cppSelf->setFinished(cppArg0);
        }
    }

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

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

static PyObject *Sbk_QNetworkReplyFunc_setHeader(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QNetworkReply *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QNetworkReply.setHeader";
    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, "setHeader", 2, 2, &(pyArgs[0]), &(pyArgs[1])))
        return {};


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

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

    // Call function/method
    {
        ::QNetworkRequest::KnownHeaders cppArg0{QNetworkRequest::ContentTypeHeader};
        pythonToCpp[0](pyArgs[0], &cppArg0);
        ::QVariant cppArg1;
        pythonToCpp[1](pyArgs[1], &cppArg1);

        if (!PyErr_Occurred()) {
            // setHeader(QNetworkRequest::KnownHeaders,QVariant)
            cppSelf->setHeader(cppArg0, cppArg1);
        }
    }

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

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

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

    // Overloaded function decisor
    // 0: QNetworkReply::setOperation(QNetworkAccessManager::Operation)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtNetworkTypes[SBK_QNETWORKACCESSMANAGER_OPERATION_IDX]))->converter, (pyArg)))) {
        overloadId = 0; // setOperation(QNetworkAccessManager::Operation)
    }

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

    // Call function/method
    {
        ::QNetworkAccessManager::Operation cppArg0{QNetworkAccessManager::UnknownOperation};
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setOperation(QNetworkAccessManager::Operation)
            cppSelf->setOperation(cppArg0);
        }
    }

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

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

static PyObject *Sbk_QNetworkReplyFunc_setRawHeader(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QNetworkReply *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QNetworkReply.setRawHeader";
    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, "setRawHeader", 2, 2, &(pyArgs[0]), &(pyArgs[1])))
        return {};


    // Overloaded function decisor
    // 0: QNetworkReply::setRawHeader(QByteArray,QByteArray)
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QBYTEARRAY_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QBYTEARRAY_IDX], (pyArgs[1])))) {
        overloadId = 0; // setRawHeader(QByteArray,QByteArray)
    }

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

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

        if (!Shiboken::Object::isValid(pyArgs[1]))
            return {};
        ::QByteArray cppArg1_local;
        ::QByteArray *cppArg1 = &cppArg1_local;
        if (pythonToCpp[1].isValue())
            pythonToCpp[1](pyArgs[1], &cppArg1_local);
        else
            pythonToCpp[1](pyArgs[1], &cppArg1);


        if (!PyErr_Occurred()) {
            // setRawHeader(QByteArray,QByteArray)
            cppSelf->setRawHeader(*cppArg0, *cppArg1);
        }
    }

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

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

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

    // Overloaded function decisor
    // 0: QNetworkReply::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_QNetworkReplyFunc_setReadBufferSize_TypeError;

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

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

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

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

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

    // Overloaded function decisor
    // 0: QNetworkReply::setRequest(QNetworkRequest)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREQUEST_IDX], (pyArg)))) {
        overloadId = 0; // setRequest(QNetworkRequest)
    }

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

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


        if (!PyErr_Occurred()) {
            // setRequest(QNetworkRequest)
            cppSelf->setRequest(*cppArg0);
        }
    }

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

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

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

    // Overloaded function decisor
    // 0: QNetworkReply::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_QNetworkReplyFunc_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_QNetworkReplyFunc_setSslConfiguration_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

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

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

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QNetworkReplyFunc_setSslConfigurationImplementation_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()) {
            // setSslConfigurationImplementation(QSslConfiguration)
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QNetworkReply::setSslConfigurationImplementation(*cppArg0)
                : cppSelf->setSslConfigurationImplementation(*cppArg0);
        }
    }

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

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

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

    // Overloaded function decisor
    // 0: QNetworkReply::setUrl(QUrl)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QURL_IDX], (pyArg)))) {
        overloadId = 0; // setUrl(QUrl)
    }

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

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


        if (!PyErr_Occurred()) {
            // setUrl(QUrl)
            cppSelf->setUrl(*cppArg0);
        }
    }

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

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

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

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // sslConfiguration()const
            QSslConfiguration cppResult = const_cast<const ::QNetworkReply *>(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_QNetworkReplyFunc_sslConfigurationImplementation(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QNetworkReply *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QNetworkReply.sslConfigurationImplementation";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

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

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QNetworkReplyFunc_sslConfigurationImplementation_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()) {
            // sslConfigurationImplementation(QSslConfiguration&)const
            Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? const_cast<const ::QNetworkReply *>(cppSelf)->::QNetworkReply::sslConfigurationImplementation(*cppArg0)
                : const_cast<const ::QNetworkReply *>(cppSelf)->sslConfigurationImplementation(*cppArg0);
        }
    }

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

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

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

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // url()const
            QUrl cppResult = const_cast<const ::QNetworkReply *>(cppSelf)->url();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QURL_IDX], &cppResult);
        }
    }

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

static PyObject *Sbk_QNetworkReplyFunc_writeData(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QNetworkReply *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtNetwork.QNetworkReply.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_QNetworkReplyFunc_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->::QNetworkReply::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_QNetworkReplyFunc_writeData_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}


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

static PyMethodDef Sbk_QNetworkReply_methods[] = {
    {"abort", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_abort), METH_NOARGS},
    {"attribute", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_attribute), METH_O},
    {"close", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_close), METH_NOARGS},
    {"error", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_error), METH_NOARGS},
    {"hasRawHeader", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_hasRawHeader), METH_O},
    {"header", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_header), METH_O},
    {"ignoreSslErrors", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_ignoreSslErrors), METH_VARARGS},
    {"ignoreSslErrorsImplementation", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_ignoreSslErrorsImplementation), METH_O},
    {"isFinished", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_isFinished), METH_NOARGS},
    {"isRunning", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_isRunning), METH_NOARGS},
    {"isSequential", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_isSequential), METH_NOARGS},
    {"manager", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_manager), METH_NOARGS},
    {"operation", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_operation), METH_NOARGS},
    {"rawHeader", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_rawHeader), METH_O},
    {"rawHeaderList", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_rawHeaderList), METH_NOARGS},
    {"rawHeaderPairs", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_rawHeaderPairs), METH_NOARGS},
    {"readBufferSize", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_readBufferSize), METH_NOARGS},
    {"request", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_request), METH_NOARGS},
    {"setAttribute", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_setAttribute), METH_VARARGS},
    {"setError", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_setError), METH_VARARGS},
    {"setFinished", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_setFinished), METH_O},
    {"setHeader", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_setHeader), METH_VARARGS},
    {"setOperation", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_setOperation), METH_O},
    {"setRawHeader", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_setRawHeader), METH_VARARGS},
    {"setReadBufferSize", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_setReadBufferSize), METH_O},
    {"setRequest", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_setRequest), METH_O},
    {"setSslConfiguration", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_setSslConfiguration), METH_O},
    {"setSslConfigurationImplementation", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_setSslConfigurationImplementation), METH_O},
    {"setUrl", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_setUrl), METH_O},
    {"sslConfiguration", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_sslConfiguration), METH_NOARGS},
    {"sslConfigurationImplementation", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_sslConfigurationImplementation), METH_O},
    {"url", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_url), METH_NOARGS},
    {"writeData", reinterpret_cast<PyCFunction>(Sbk_QNetworkReplyFunc_writeData), METH_VARARGS},

    {nullptr, nullptr} // Sentinel
};

static int Sbk_QNetworkReply_setattro(PyObject *self, PyObject *name, PyObject *value)
{
    PySide::Feature::Select(self);
    if (value && PyCallable_Check(value)) {
        auto plain_inst = reinterpret_cast< ::QNetworkReply *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_IDX], reinterpret_cast<SbkObject *>(self)));
        auto inst = dynamic_cast<QNetworkReplyWrapper *>(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_QNetworkReply_traverse(PyObject *self, visitproc visit, void *arg)
{
    return SbkObject_TypeF()->tp_traverse(self, visit, arg);
}
static int Sbk_QNetworkReply_clear(PyObject *self)
{
    return reinterpret_cast<PyTypeObject *>(SbkObject_TypeF())->tp_clear(self);
}
static void * Sbk_QNetworkReplySpecialCastFunction(void *obj, PyTypeObject *desiredType)
{
    auto me = reinterpret_cast< ::QNetworkReply *>(obj);
    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_QNetworkReply_Type = nullptr;
static PyTypeObject *Sbk_QNetworkReply_TypeF(void)
{
    return _Sbk_QNetworkReply_Type;
}

static PyType_Slot Sbk_QNetworkReply_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_QNetworkReply_setattro)},
    {Py_tp_traverse,    reinterpret_cast<void *>(Sbk_QNetworkReply_traverse)},
    {Py_tp_clear,       reinterpret_cast<void *>(Sbk_QNetworkReply_clear)},
    {Py_tp_richcompare, nullptr},
    {Py_tp_iter,        nullptr},
    {Py_tp_iternext,    nullptr},
    {Py_tp_methods,     reinterpret_cast<void *>(Sbk_QNetworkReply_methods)},
    {Py_tp_getset,      nullptr},
    {Py_tp_init,        reinterpret_cast<void *>(Sbk_QNetworkReply_Init)},
    {Py_tp_new,         reinterpret_cast<void *>(SbkObjectTpNew)},
    {0, nullptr}
};
static PyType_Spec Sbk_QNetworkReply_spec = {
    "2:PySide6.QtNetwork.QNetworkReply",
    sizeof(SbkObject),
    0,
    Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
    Sbk_QNetworkReply_slots
};

} //extern "C"

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


// Type conversion functions.

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

}
static PythonToCppFunc is_QNetworkReply_NetworkError_PythonToCpp_QNetworkReply_NetworkError_Convertible(PyObject *pyIn)
{
    if (PyObject_TypeCheck(pyIn, SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX]))
        return QNetworkReply_NetworkError_PythonToCpp_QNetworkReply_NetworkError;
    return {};
}
static PyObject *QNetworkReply_NetworkError_CppToPython_QNetworkReply_NetworkError(const void *cppIn)
{
    const int castCppIn = int(*reinterpret_cast<const ::QNetworkReply::NetworkError *>(cppIn));
    return Shiboken::Enum::newItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX], castCppIn);

}

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

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

}

// The signatures string for the functions.
// Multiple signatures have their index "n:" in front.
static const char *QNetworkReply_SignatureStrings[] = {
    "PySide6.QtNetwork.QNetworkReply(self,parent:PySide6.QtCore.QObject=nullptr)",
    "PySide6.QtNetwork.QNetworkReply.abort(self)",
    "PySide6.QtNetwork.QNetworkReply.attribute(self,code:PySide6.QtNetwork.QNetworkRequest.Attribute)->QVariant",
    "PySide6.QtNetwork.QNetworkReply.close(self)",
    "PySide6.QtNetwork.QNetworkReply.error(self)->PySide6.QtNetwork.QNetworkReply.NetworkError",
    "PySide6.QtNetwork.QNetworkReply.hasRawHeader(self,headerName:typing.Union[PySide6.QtCore.QByteArray, char*])->bool",
    "PySide6.QtNetwork.QNetworkReply.header(self,header:PySide6.QtNetwork.QNetworkRequest.KnownHeaders)->QVariant",
    "1:PySide6.QtNetwork.QNetworkReply.ignoreSslErrors(self)",
    "0:PySide6.QtNetwork.QNetworkReply.ignoreSslErrors(self,errors:QList[PySide6.QtNetwork.QSslError])",
    "PySide6.QtNetwork.QNetworkReply.ignoreSslErrorsImplementation(self,arg__1:QList[PySide6.QtNetwork.QSslError])",
    "PySide6.QtNetwork.QNetworkReply.isFinished(self)->bool",
    "PySide6.QtNetwork.QNetworkReply.isRunning(self)->bool",
    "PySide6.QtNetwork.QNetworkReply.isSequential(self)->bool",
    "PySide6.QtNetwork.QNetworkReply.manager(self)->PySide6.QtNetwork.QNetworkAccessManager",
    "PySide6.QtNetwork.QNetworkReply.operation(self)->PySide6.QtNetwork.QNetworkAccessManager.Operation",
    "PySide6.QtNetwork.QNetworkReply.rawHeader(self,headerName:typing.Union[PySide6.QtCore.QByteArray, char*])->PySide6.QtCore.QByteArray",
    "PySide6.QtNetwork.QNetworkReply.rawHeaderList(self)->QList[PySide6.QtCore.QByteArray]",
    "PySide6.QtNetwork.QNetworkReply.rawHeaderPairs(self)->QList[std.pair[PySide6.QtCore.QByteArray, PySide6.QtCore.QByteArray]]",
    "PySide6.QtNetwork.QNetworkReply.readBufferSize(self)->qint64",
    "PySide6.QtNetwork.QNetworkReply.request(self)->PySide6.QtNetwork.QNetworkRequest",
    "PySide6.QtNetwork.QNetworkReply.setAttribute(self,code:PySide6.QtNetwork.QNetworkRequest.Attribute,value:QVariant)",
    "PySide6.QtNetwork.QNetworkReply.setError(self,errorCode:PySide6.QtNetwork.QNetworkReply.NetworkError,errorString:QString)",
    "PySide6.QtNetwork.QNetworkReply.setFinished(self,arg__1:bool)",
    "PySide6.QtNetwork.QNetworkReply.setHeader(self,header:PySide6.QtNetwork.QNetworkRequest.KnownHeaders,value:QVariant)",
    "PySide6.QtNetwork.QNetworkReply.setOperation(self,operation:PySide6.QtNetwork.QNetworkAccessManager.Operation)",
    "PySide6.QtNetwork.QNetworkReply.setRawHeader(self,headerName:typing.Union[PySide6.QtCore.QByteArray, char*],value:typing.Union[PySide6.QtCore.QByteArray, char*])",
    "PySide6.QtNetwork.QNetworkReply.setReadBufferSize(self,size:qint64)",
    "PySide6.QtNetwork.QNetworkReply.setRequest(self,request:PySide6.QtNetwork.QNetworkRequest)",
    "PySide6.QtNetwork.QNetworkReply.setSslConfiguration(self,configuration:PySide6.QtNetwork.QSslConfiguration)",
    "PySide6.QtNetwork.QNetworkReply.setSslConfigurationImplementation(self,arg__1:PySide6.QtNetwork.QSslConfiguration)",
    "PySide6.QtNetwork.QNetworkReply.setUrl(self,url:typing.Union[PySide6.QtCore.QUrl, QString])",
    "PySide6.QtNetwork.QNetworkReply.sslConfiguration(self)->PySide6.QtNetwork.QSslConfiguration",
    "PySide6.QtNetwork.QNetworkReply.sslConfigurationImplementation(self,arg__1:PySide6.QtNetwork.QSslConfiguration)",
    "PySide6.QtNetwork.QNetworkReply.url(self)->PySide6.QtCore.QUrl",
    "PySide6.QtNetwork.QNetworkReply.writeData(self,data:char*,len:qint64)->qint64",
    nullptr}; // Sentinel

void init_QNetworkReply(PyObject *module)
{
    _Sbk_QNetworkReply_Type = Shiboken::ObjectType::introduceWrapperType(
        module,
        "QNetworkReply",
        "QNetworkReply*",
        &Sbk_QNetworkReply_spec,
        &Shiboken::callCppDestructor< ::QNetworkReply >,
        SbkPySide6_QtCoreTypes[SBK_QIODEVICE_IDX],
        0,
        0);
    auto *pyType = Sbk_QNetworkReply_TypeF(); // references _Sbk_QNetworkReply_Type
    InitSignatureStrings(pyType, QNetworkReply_SignatureStrings);
    SbkObjectType_SetPropertyStrings(reinterpret_cast<PyTypeObject *>(_Sbk_QNetworkReply_Type), Sbk_QNetworkReply_PropertyStrings);
    SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_IDX]
        = Sbk_QNetworkReply_TypeF();

    // Register Converter
    SbkConverter *converter = Shiboken::Conversions::createConverter(Sbk_QNetworkReply_TypeF(),
        QNetworkReply_PythonToCpp_QNetworkReply_PTR,
        is_QNetworkReply_PythonToCpp_QNetworkReply_PTR_Convertible,
        QNetworkReply_PTR_CppToPython_QNetworkReply);

    Shiboken::Conversions::registerConverterName(converter, "QNetworkReply");
    Shiboken::Conversions::registerConverterName(converter, "QNetworkReply*");
    Shiboken::Conversions::registerConverterName(converter, "QNetworkReply&");
    Shiboken::Conversions::registerConverterName(converter, typeid(::QNetworkReply).name());
    Shiboken::Conversions::registerConverterName(converter, typeid(::QNetworkReplyWrapper).name());


    MultipleInheritanceInitFunction func = Shiboken::ObjectType::getMultipleInheritanceFunction(SbkPySide6_QtCoreTypes[SBK_QIODEVICE_IDX]);
    Shiboken::ObjectType::setMultipleInheritanceFunction(Sbk_QNetworkReply_TypeF(), func);
    Shiboken::ObjectType::setCastFunction(Sbk_QNetworkReply_TypeF(), &Sbk_QNetworkReplySpecialCastFunction);
    Shiboken::ObjectType::setTypeDiscoveryFunctionV2(Sbk_QNetworkReply_TypeF(), &Sbk_QNetworkReply_typeDiscovery);

    // Initialization of enums.

    // Initialization of enum 'NetworkError'.
    SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX] = Shiboken::Enum::createScopedEnum(Sbk_QNetworkReply_TypeF(),
        "NetworkError",
        "2:PySide6.QtNetwork.QNetworkReply.NetworkError",
        "QNetworkReply::NetworkError");
    if (!SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX])
        return;

    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "NoError", (long) QNetworkReply::NetworkError::NoError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ConnectionRefusedError", (long) QNetworkReply::NetworkError::ConnectionRefusedError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "RemoteHostClosedError", (long) QNetworkReply::NetworkError::RemoteHostClosedError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "HostNotFoundError", (long) QNetworkReply::NetworkError::HostNotFoundError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "TimeoutError", (long) QNetworkReply::NetworkError::TimeoutError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "OperationCanceledError", (long) QNetworkReply::NetworkError::OperationCanceledError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "SslHandshakeFailedError", (long) QNetworkReply::NetworkError::SslHandshakeFailedError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "TemporaryNetworkFailureError", (long) QNetworkReply::NetworkError::TemporaryNetworkFailureError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "NetworkSessionFailedError", (long) QNetworkReply::NetworkError::NetworkSessionFailedError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "BackgroundRequestNotAllowedError", (long) QNetworkReply::NetworkError::BackgroundRequestNotAllowedError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "TooManyRedirectsError", (long) QNetworkReply::NetworkError::TooManyRedirectsError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "InsecureRedirectError", (long) QNetworkReply::NetworkError::InsecureRedirectError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "UnknownNetworkError", (long) QNetworkReply::NetworkError::UnknownNetworkError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ProxyConnectionRefusedError", (long) QNetworkReply::NetworkError::ProxyConnectionRefusedError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ProxyConnectionClosedError", (long) QNetworkReply::NetworkError::ProxyConnectionClosedError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ProxyNotFoundError", (long) QNetworkReply::NetworkError::ProxyNotFoundError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ProxyTimeoutError", (long) QNetworkReply::NetworkError::ProxyTimeoutError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ProxyAuthenticationRequiredError", (long) QNetworkReply::NetworkError::ProxyAuthenticationRequiredError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "UnknownProxyError", (long) QNetworkReply::NetworkError::UnknownProxyError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ContentAccessDenied", (long) QNetworkReply::NetworkError::ContentAccessDenied))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ContentOperationNotPermittedError", (long) QNetworkReply::NetworkError::ContentOperationNotPermittedError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ContentNotFoundError", (long) QNetworkReply::NetworkError::ContentNotFoundError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "AuthenticationRequiredError", (long) QNetworkReply::NetworkError::AuthenticationRequiredError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ContentReSendError", (long) QNetworkReply::NetworkError::ContentReSendError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ContentConflictError", (long) QNetworkReply::NetworkError::ContentConflictError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ContentGoneError", (long) QNetworkReply::NetworkError::ContentGoneError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "UnknownContentError", (long) QNetworkReply::NetworkError::UnknownContentError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ProtocolUnknownError", (long) QNetworkReply::NetworkError::ProtocolUnknownError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ProtocolInvalidOperationError", (long) QNetworkReply::NetworkError::ProtocolInvalidOperationError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ProtocolFailure", (long) QNetworkReply::NetworkError::ProtocolFailure))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "InternalServerError", (long) QNetworkReply::NetworkError::InternalServerError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "OperationNotImplementedError", (long) QNetworkReply::NetworkError::OperationNotImplementedError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "ServiceUnavailableError", (long) QNetworkReply::NetworkError::ServiceUnavailableError))
        return;
    if (!Shiboken::Enum::createScopedEnumItem(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
        Sbk_QNetworkReply_TypeF(), "UnknownServerError", (long) QNetworkReply::NetworkError::UnknownServerError))
        return;
    // Register converter for enum 'QNetworkReply::NetworkError'.
    {
        SbkConverter *converter = Shiboken::Conversions::createConverter(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX],
            QNetworkReply_NetworkError_CppToPython_QNetworkReply_NetworkError);
        Shiboken::Conversions::addPythonToCppValueConversion(converter,
            QNetworkReply_NetworkError_PythonToCpp_QNetworkReply_NetworkError,
            is_QNetworkReply_NetworkError_PythonToCpp_QNetworkReply_NetworkError_Convertible);
        Shiboken::Enum::setTypeConverter(SbkPySide6_QtNetworkTypes[SBK_QNETWORKREPLY_NETWORKERROR_IDX], converter, false);
        Shiboken::Conversions::registerConverterName(converter, "QNetworkReply::NetworkError");
        Shiboken::Conversions::registerConverterName(converter, "NetworkError");
    }
    // End of 'NetworkError' enum.

    PySide::Signal::registerSignals(Sbk_QNetworkReply_TypeF(), &::QNetworkReply::staticMetaObject);
    qRegisterMetaType< ::QNetworkReply::NetworkError >("QNetworkReply::NetworkError");
    Shiboken::ObjectType::setSubTypeInitHook(Sbk_QNetworkReply_TypeF(), &PySide::initQObjectSubType);
    PySide::initDynamicMetaObject(Sbk_QNetworkReply_TypeF(), &::QNetworkReply::staticMetaObject, sizeof(QNetworkReplyWrapper));
}
