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

#include "sipAPIQtWebEngineCore.h"

#line 28 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/sip/QtWebEngineCore/qwebengineurlrequestjob.sip"
#include <qwebengineurlrequestjob.h>
#line 29 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"

#line 27 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qpycore_qmap.sip"
#include <qmap.h>
#line 33 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 30 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 36 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 109 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qurl.sip"
#include <qurl.h>
#line 39 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 26 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qiodevice.sip"
#include <qiodevice.h>
#line 42 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 26 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 146 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 47 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 26 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qmetaobject.sip"
#include <qmetaobject.h>
#line 50 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 26 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 53 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 247 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 56 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 235 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 59 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 28 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qobject.sip"
#include <qobject.h>
#line 62 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 27 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qstring.sip"
#include <qstring.h>
#line 65 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 26 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qvariant.sip"
#include <qvariant.h>
#line 68 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 38 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 71 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 149 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 74 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 26 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 77 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 26 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qthread.sip"
#include <qthread.h>
#line 80 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 26 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 83 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 26 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qregexp.sip"
#include <qregexp.h>
#line 86 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 26 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qregularexpression.sip"
#include <qregularexpression.h>
#line 89 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"
#line 26 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 92 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineCore/sipQtWebEngineCoreQWebEngineUrlRequestJob.cpp"


PyDoc_STRVAR(doc_QWebEngineUrlRequestJob_requestUrl, "requestUrl(self) -> QUrl");

extern "C" {static PyObject *meth_QWebEngineUrlRequestJob_requestUrl(PyObject *, PyObject *);}
static PyObject *meth_QWebEngineUrlRequestJob_requestUrl(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QWebEngineUrlRequestJob *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineUrlRequestJob, &sipCpp))
        {
             ::QUrl*sipRes;

            sipRes = new  ::QUrl(sipCpp->requestUrl());

            return sipConvertFromNewType(sipRes,sipType_QUrl,SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineUrlRequestJob, sipName_requestUrl, doc_QWebEngineUrlRequestJob_requestUrl);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineUrlRequestJob_requestMethod, "requestMethod(self) -> QByteArray");

extern "C" {static PyObject *meth_QWebEngineUrlRequestJob_requestMethod(PyObject *, PyObject *);}
static PyObject *meth_QWebEngineUrlRequestJob_requestMethod(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QWebEngineUrlRequestJob *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineUrlRequestJob, &sipCpp))
        {
             ::QByteArray*sipRes;

            sipRes = new  ::QByteArray(sipCpp->requestMethod());

            return sipConvertFromNewType(sipRes,sipType_QByteArray,SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineUrlRequestJob, sipName_requestMethod, doc_QWebEngineUrlRequestJob_requestMethod);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineUrlRequestJob_reply, "reply(self, Union[QByteArray, bytes, bytearray], QIODevice)");

extern "C" {static PyObject *meth_QWebEngineUrlRequestJob_reply(PyObject *, PyObject *);}
static PyObject *meth_QWebEngineUrlRequestJob_reply(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QByteArray* a0;
        int a0State = 0;
         ::QIODevice* a1;
         ::QWebEngineUrlRequestJob *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J8", &sipSelf, sipType_QWebEngineUrlRequestJob, &sipCpp, sipType_QByteArray, &a0, &a0State, sipType_QIODevice, &a1))
        {
            sipCpp->reply(*a0,a1);
            sipReleaseType(const_cast< ::QByteArray *>(a0), sipType_QByteArray, a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineUrlRequestJob, sipName_reply, doc_QWebEngineUrlRequestJob_reply);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineUrlRequestJob_fail, "fail(self, QWebEngineUrlRequestJob.Error)");

extern "C" {static PyObject *meth_QWebEngineUrlRequestJob_fail(PyObject *, PyObject *);}
static PyObject *meth_QWebEngineUrlRequestJob_fail(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
         ::QWebEngineUrlRequestJob::Error a0;
         ::QWebEngineUrlRequestJob *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BE", &sipSelf, sipType_QWebEngineUrlRequestJob, &sipCpp, sipType_QWebEngineUrlRequestJob_Error, &a0))
        {
            sipCpp->fail(a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineUrlRequestJob, sipName_fail, doc_QWebEngineUrlRequestJob_fail);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineUrlRequestJob_redirect, "redirect(self, QUrl)");

extern "C" {static PyObject *meth_QWebEngineUrlRequestJob_redirect(PyObject *, PyObject *);}
static PyObject *meth_QWebEngineUrlRequestJob_redirect(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QUrl* a0;
         ::QWebEngineUrlRequestJob *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QWebEngineUrlRequestJob, &sipCpp, sipType_QUrl, &a0))
        {
            sipCpp->redirect(*a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineUrlRequestJob, sipName_redirect, doc_QWebEngineUrlRequestJob_redirect);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineUrlRequestJob_initiator, "initiator(self) -> QUrl");

extern "C" {static PyObject *meth_QWebEngineUrlRequestJob_initiator(PyObject *, PyObject *);}
static PyObject *meth_QWebEngineUrlRequestJob_initiator(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QWebEngineUrlRequestJob *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineUrlRequestJob, &sipCpp))
        {
             ::QUrl*sipRes;

            sipRes = new  ::QUrl(sipCpp->initiator());

            return sipConvertFromNewType(sipRes,sipType_QUrl,SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineUrlRequestJob, sipName_initiator, doc_QWebEngineUrlRequestJob_initiator);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineUrlRequestJob_requestHeaders, "requestHeaders(self) -> Dict[QByteArray, QByteArray]");

extern "C" {static PyObject *meth_QWebEngineUrlRequestJob_requestHeaders(PyObject *, PyObject *);}
static PyObject *meth_QWebEngineUrlRequestJob_requestHeaders(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QWebEngineUrlRequestJob *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineUrlRequestJob, &sipCpp))
        {
            QMap< ::QByteArray, ::QByteArray>*sipRes;

            sipRes = new QMap< ::QByteArray, ::QByteArray>(sipCpp->requestHeaders());

            return sipConvertFromNewType(sipRes,sipType_QMap_0100QByteArray_0100QByteArray,SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineUrlRequestJob, sipName_requestHeaders, doc_QWebEngineUrlRequestJob_requestHeaders);

    return SIP_NULLPTR;
}


/* Cast a pointer to a type somewhere in its inheritance hierarchy. */
extern "C" {static void *cast_QWebEngineUrlRequestJob(void *, const sipTypeDef *);}
static void *cast_QWebEngineUrlRequestJob(void *sipCppV, const sipTypeDef *targetType)
{
     ::QWebEngineUrlRequestJob *sipCpp = reinterpret_cast< ::QWebEngineUrlRequestJob *>(sipCppV);

    if (targetType == sipType_QWebEngineUrlRequestJob)
        return sipCppV;

    if (targetType == sipType_QObject)
        return static_cast< ::QObject *>(sipCpp);

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_QWebEngineUrlRequestJob(void *, int);}
static void release_QWebEngineUrlRequestJob(void *sipCppV, int)
{
     ::QWebEngineUrlRequestJob *sipCpp = reinterpret_cast< ::QWebEngineUrlRequestJob *>(sipCppV);

    if (QThread::currentThread() == sipCpp->thread())
        delete sipCpp;
    else
        sipCpp->deleteLater();
}


extern "C" {static void dealloc_QWebEngineUrlRequestJob(sipSimpleWrapper *);}
static void dealloc_QWebEngineUrlRequestJob(sipSimpleWrapper *sipSelf)
{
    if (sipIsOwnedByPython(sipSelf))
    {
        release_QWebEngineUrlRequestJob(sipGetAddress(sipSelf), 0);
    }
}


/* Define this type's super-types. */
static sipEncodedTypeDef supers_QWebEngineUrlRequestJob[] = {{5, 0, 1}};


static PyMethodDef methods_QWebEngineUrlRequestJob[] = {
    {sipName_fail, meth_QWebEngineUrlRequestJob_fail, METH_VARARGS, doc_QWebEngineUrlRequestJob_fail},
    {sipName_initiator, meth_QWebEngineUrlRequestJob_initiator, METH_VARARGS, doc_QWebEngineUrlRequestJob_initiator},
    {sipName_redirect, meth_QWebEngineUrlRequestJob_redirect, METH_VARARGS, doc_QWebEngineUrlRequestJob_redirect},
    {sipName_reply, meth_QWebEngineUrlRequestJob_reply, METH_VARARGS, doc_QWebEngineUrlRequestJob_reply},
    {sipName_requestHeaders, meth_QWebEngineUrlRequestJob_requestHeaders, METH_VARARGS, doc_QWebEngineUrlRequestJob_requestHeaders},
    {sipName_requestMethod, meth_QWebEngineUrlRequestJob_requestMethod, METH_VARARGS, doc_QWebEngineUrlRequestJob_requestMethod},
    {sipName_requestUrl, meth_QWebEngineUrlRequestJob_requestUrl, METH_VARARGS, doc_QWebEngineUrlRequestJob_requestUrl}
};

static sipEnumMemberDef enummembers_QWebEngineUrlRequestJob[] = {
    {sipName_NoError, static_cast<int>( ::QWebEngineUrlRequestJob::NoError), 18},
    {sipName_RequestAborted, static_cast<int>( ::QWebEngineUrlRequestJob::RequestAborted), 18},
    {sipName_RequestDenied, static_cast<int>( ::QWebEngineUrlRequestJob::RequestDenied), 18},
    {sipName_RequestFailed, static_cast<int>( ::QWebEngineUrlRequestJob::RequestFailed), 18},
    {sipName_UrlInvalid, static_cast<int>( ::QWebEngineUrlRequestJob::UrlInvalid), 18},
    {sipName_UrlNotFound, static_cast<int>( ::QWebEngineUrlRequestJob::UrlNotFound), 18},
};


static pyqt5ClassPluginDef plugin_QWebEngineUrlRequestJob = {
    & ::QWebEngineUrlRequestJob::staticMetaObject,
    0,
    SIP_NULLPTR,
    SIP_NULLPTR
};


sipClassTypeDef sipTypeDef_QtWebEngineCore_QWebEngineUrlRequestJob = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_SCC|SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QWebEngineUrlRequestJob,
        SIP_NULLPTR,
        &plugin_QWebEngineUrlRequestJob
    },
    {
        sipNameNr_QWebEngineUrlRequestJob,
        {0, 0, 1},
        7, methods_QWebEngineUrlRequestJob,
        6, enummembers_QWebEngineUrlRequestJob,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    SIP_NULLPTR,
    -1,
    -1,
    supers_QWebEngineUrlRequestJob,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QWebEngineUrlRequestJob,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    release_QWebEngineUrlRequestJob,
    cast_QWebEngineUrlRequestJob,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    0,
};
