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

#line 26 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/sip/QtWebEngineWidgets/qwebenginecertificateerror.sip"
#include <qwebenginecertificateerror.h>
#line 29 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineWidgets/sipQtWebEngineWidgetsQWebEngineCertificateError.cpp"

#line 38 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 33 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineWidgets/sipQtWebEngineWidgetsQWebEngineCertificateError.cpp"
#line 28 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtNetwork/qsslcertificate.sip"
#include <qsslcertificate.h>
#line 36 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineWidgets/sipQtWebEngineWidgetsQWebEngineCertificateError.cpp"
#line 27 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qstring.sip"
#include <qstring.h>
#line 39 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineWidgets/sipQtWebEngineWidgetsQWebEngineCertificateError.cpp"
#line 109 "/usr/lib/python3.10/site-packages/PyQt5/bindings/QtCore/qurl.sip"
#include <qurl.h>
#line 42 "/build/pyqt5-webengine/src/PyQtWebEngine-5.15.6/build/QtWebEngineWidgets/sipQtWebEngineWidgetsQWebEngineCertificateError.cpp"


PyDoc_STRVAR(doc_QWebEngineCertificateError_error, "error(self) -> QWebEngineCertificateError.Error");

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

    {
        const  ::QWebEngineCertificateError *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineCertificateError, &sipCpp))
        {
             ::QWebEngineCertificateError::Error sipRes;

            sipRes = sipCpp->error();

            return sipConvertFromEnum(static_cast<int>(sipRes), sipType_QWebEngineCertificateError_Error);
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineCertificateError, sipName_error, doc_QWebEngineCertificateError_error);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineCertificateError_url, "url(self) -> QUrl");

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

    {
        const  ::QWebEngineCertificateError *sipCpp;

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

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

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

    sipNoMethod(sipParseErr, sipName_QWebEngineCertificateError, sipName_url, doc_QWebEngineCertificateError_url);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineCertificateError_isOverridable, "isOverridable(self) -> bool");

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

    {
        const  ::QWebEngineCertificateError *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineCertificateError, &sipCpp))
        {
            bool sipRes;

            sipRes = sipCpp->isOverridable();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineCertificateError, sipName_isOverridable, doc_QWebEngineCertificateError_isOverridable);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineCertificateError_errorDescription, "errorDescription(self) -> str");

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

    {
        const  ::QWebEngineCertificateError *sipCpp;

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

            sipRes = new  ::QString(sipCpp->errorDescription());

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

    sipNoMethod(sipParseErr, sipName_QWebEngineCertificateError, sipName_errorDescription, doc_QWebEngineCertificateError_errorDescription);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineCertificateError_defer, "defer(self)");

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

    {
         ::QWebEngineCertificateError *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineCertificateError, &sipCpp))
        {
            sipCpp->defer();

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineCertificateError, sipName_defer, doc_QWebEngineCertificateError_defer);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineCertificateError_deferred, "deferred(self) -> bool");

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

    {
        const  ::QWebEngineCertificateError *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineCertificateError, &sipCpp))
        {
            bool sipRes;

            sipRes = sipCpp->deferred();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineCertificateError, sipName_deferred, doc_QWebEngineCertificateError_deferred);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineCertificateError_rejectCertificate, "rejectCertificate(self)");

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

    {
         ::QWebEngineCertificateError *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineCertificateError, &sipCpp))
        {
            sipCpp->rejectCertificate();

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineCertificateError, sipName_rejectCertificate, doc_QWebEngineCertificateError_rejectCertificate);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineCertificateError_ignoreCertificateError, "ignoreCertificateError(self)");

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

    {
         ::QWebEngineCertificateError *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineCertificateError, &sipCpp))
        {
            sipCpp->ignoreCertificateError();

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineCertificateError, sipName_ignoreCertificateError, doc_QWebEngineCertificateError_ignoreCertificateError);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineCertificateError_answered, "answered(self) -> bool");

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

    {
        const  ::QWebEngineCertificateError *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineCertificateError, &sipCpp))
        {
            bool sipRes;

            sipRes = sipCpp->answered();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QWebEngineCertificateError, sipName_answered, doc_QWebEngineCertificateError_answered);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QWebEngineCertificateError_certificateChain, "certificateChain(self) -> List[QSslCertificate]");

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

    {
        const  ::QWebEngineCertificateError *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QWebEngineCertificateError, &sipCpp))
        {
            QList< ::QSslCertificate>*sipRes;

            sipRes = new QList< ::QSslCertificate>(sipCpp->certificateChain());

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

    sipNoMethod(sipParseErr, sipName_QWebEngineCertificateError, sipName_certificateChain, doc_QWebEngineCertificateError_certificateChain);

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_QWebEngineCertificateError(void *, int);}
static void release_QWebEngineCertificateError(void *sipCppV, int)
{
    delete reinterpret_cast< ::QWebEngineCertificateError *>(sipCppV);
}


extern "C" {static void assign_QWebEngineCertificateError(void *, Py_ssize_t, void *);}
static void assign_QWebEngineCertificateError(void *sipDst, Py_ssize_t sipDstIdx, void *sipSrc)
{
    reinterpret_cast< ::QWebEngineCertificateError *>(sipDst)[sipDstIdx] = *reinterpret_cast< ::QWebEngineCertificateError *>(sipSrc);
}


extern "C" {static void *copy_QWebEngineCertificateError(const void *, Py_ssize_t);}
static void *copy_QWebEngineCertificateError(const void *sipSrc, Py_ssize_t sipSrcIdx)
{
    return new  ::QWebEngineCertificateError(reinterpret_cast<const  ::QWebEngineCertificateError *>(sipSrc)[sipSrcIdx]);
}


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


extern "C" {static void *init_type_QWebEngineCertificateError(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_QWebEngineCertificateError(sipSimpleWrapper *, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **, PyObject **sipParseErr)
{
     ::QWebEngineCertificateError *sipCpp = SIP_NULLPTR;

    {
        const  ::QWebEngineCertificateError* a0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, "J9", sipType_QWebEngineCertificateError, &a0))
        {
            sipCpp = new  ::QWebEngineCertificateError(*a0);

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


static PyMethodDef methods_QWebEngineCertificateError[] = {
    {sipName_answered, meth_QWebEngineCertificateError_answered, METH_VARARGS, doc_QWebEngineCertificateError_answered},
    {sipName_certificateChain, meth_QWebEngineCertificateError_certificateChain, METH_VARARGS, doc_QWebEngineCertificateError_certificateChain},
    {sipName_defer, meth_QWebEngineCertificateError_defer, METH_VARARGS, doc_QWebEngineCertificateError_defer},
    {sipName_deferred, meth_QWebEngineCertificateError_deferred, METH_VARARGS, doc_QWebEngineCertificateError_deferred},
    {sipName_error, meth_QWebEngineCertificateError_error, METH_VARARGS, doc_QWebEngineCertificateError_error},
    {sipName_errorDescription, meth_QWebEngineCertificateError_errorDescription, METH_VARARGS, doc_QWebEngineCertificateError_errorDescription},
    {sipName_ignoreCertificateError, meth_QWebEngineCertificateError_ignoreCertificateError, METH_VARARGS, doc_QWebEngineCertificateError_ignoreCertificateError},
    {sipName_isOverridable, meth_QWebEngineCertificateError_isOverridable, METH_VARARGS, doc_QWebEngineCertificateError_isOverridable},
    {sipName_rejectCertificate, meth_QWebEngineCertificateError_rejectCertificate, METH_VARARGS, doc_QWebEngineCertificateError_rejectCertificate},
    {sipName_url, meth_QWebEngineCertificateError_url, METH_VARARGS, doc_QWebEngineCertificateError_url}
};

static sipEnumMemberDef enummembers_QWebEngineCertificateError[] = {
    {sipName_CertificateAuthorityInvalid, static_cast<int>( ::QWebEngineCertificateError::CertificateAuthorityInvalid), 3},
    {sipName_CertificateCommonNameInvalid, static_cast<int>( ::QWebEngineCertificateError::CertificateCommonNameInvalid), 3},
    {sipName_CertificateContainsErrors, static_cast<int>( ::QWebEngineCertificateError::CertificateContainsErrors), 3},
    {sipName_CertificateDateInvalid, static_cast<int>( ::QWebEngineCertificateError::CertificateDateInvalid), 3},
    {sipName_CertificateInvalid, static_cast<int>( ::QWebEngineCertificateError::CertificateInvalid), 3},
    {sipName_CertificateKnownInterceptionBlocked, static_cast<int>( ::QWebEngineCertificateError::CertificateKnownInterceptionBlocked), 3},
    {sipName_CertificateNameConstraintViolation, static_cast<int>( ::QWebEngineCertificateError::CertificateNameConstraintViolation), 3},
    {sipName_CertificateNoRevocationMechanism, static_cast<int>( ::QWebEngineCertificateError::CertificateNoRevocationMechanism), 3},
    {sipName_CertificateNonUniqueName, static_cast<int>( ::QWebEngineCertificateError::CertificateNonUniqueName), 3},
    {sipName_CertificateRevoked, static_cast<int>( ::QWebEngineCertificateError::CertificateRevoked), 3},
    {sipName_CertificateTransparencyRequired, static_cast<int>( ::QWebEngineCertificateError::CertificateTransparencyRequired), 3},
    {sipName_CertificateUnableToCheckRevocation, static_cast<int>( ::QWebEngineCertificateError::CertificateUnableToCheckRevocation), 3},
    {sipName_CertificateValidityTooLong, static_cast<int>( ::QWebEngineCertificateError::CertificateValidityTooLong), 3},
    {sipName_CertificateWeakKey, static_cast<int>( ::QWebEngineCertificateError::CertificateWeakKey), 3},
    {sipName_CertificateWeakSignatureAlgorithm, static_cast<int>( ::QWebEngineCertificateError::CertificateWeakSignatureAlgorithm), 3},
    {sipName_SslPinnedKeyNotInCertificateChain, static_cast<int>( ::QWebEngineCertificateError::SslPinnedKeyNotInCertificateChain), 3},
};

PyDoc_STRVAR(doc_QWebEngineCertificateError, "\1QWebEngineCertificateError(QWebEngineCertificateError)");


static pyqt5ClassPluginDef plugin_QWebEngineCertificateError = {
    SIP_NULLPTR,
    0,
    SIP_NULLPTR,
    SIP_NULLPTR
};


sipClassTypeDef sipTypeDef_QtWebEngineWidgets_QWebEngineCertificateError = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QWebEngineCertificateError,
        SIP_NULLPTR,
        &plugin_QWebEngineCertificateError
    },
    {
        sipNameNr_QWebEngineCertificateError,
        {0, 0, 1},
        10, methods_QWebEngineCertificateError,
        16, enummembers_QWebEngineCertificateError,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QWebEngineCertificateError,
    -1,
    sipNameNr_sip_simplewrapper,
    SIP_NULLPTR,
    SIP_NULLPTR,
    init_type_QWebEngineCertificateError,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QWebEngineCertificateError,
    assign_QWebEngineCertificateError,
    SIP_NULLPTR,
    copy_QWebEngineCertificateError,
    release_QWebEngineCertificateError,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    sizeof ( ::QWebEngineCertificateError),
};
