/*
 * Interface wrapper code.
 *
 * Generated by SIP 4.19.23
 *
 * Copyright (c) 2020 Riverbank Computing Limited <info@riverbankcomputing.com>
 * 
 * This file is part of PyQt5.
 * 
 * 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 "sipAPIQtNetwork.h"

#line 29 "/scratch/jenkins-BUILDS-eSDK-2023.1_stable-pipeline-build_async-47_k26_smk_kv_full/build/tmp/work/cortexa72-cortexa53-xilinx-linux/python3-pyqt5/5.15.1-r0/PyQt5-5.15.1/sip/QtNetwork/qssldiffiehellmanparameters.sip"
#include <qssldiffiehellmanparameters.h>
#line 29 "/scratch/jenkins-BUILDS-eSDK-2023.1_stable-pipeline-build_async-47_k26_smk_kv_full/build/tmp/work/cortexa72-cortexa53-xilinx-linux/python3-pyqt5/5.15.1-r0/PyQt5-5.15.1/QtNetwork/sipQtNetworkQSslDiffieHellmanParameters.cpp"

#line 27 "sip/QtCore/qstring.sip"
#include <qstring.h>
#line 33 "/scratch/jenkins-BUILDS-eSDK-2023.1_stable-pipeline-build_async-47_k26_smk_kv_full/build/tmp/work/cortexa72-cortexa53-xilinx-linux/python3-pyqt5/5.15.1-r0/PyQt5-5.15.1/QtNetwork/sipQtNetworkQSslDiffieHellmanParameters.cpp"
#line 30 "sip/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 36 "/scratch/jenkins-BUILDS-eSDK-2023.1_stable-pipeline-build_async-47_k26_smk_kv_full/build/tmp/work/cortexa72-cortexa53-xilinx-linux/python3-pyqt5/5.15.1-r0/PyQt5-5.15.1/QtNetwork/sipQtNetworkQSslDiffieHellmanParameters.cpp"
#line 28 "/scratch/jenkins-BUILDS-eSDK-2023.1_stable-pipeline-build_async-47_k26_smk_kv_full/build/tmp/work/cortexa72-cortexa53-xilinx-linux/python3-pyqt5/5.15.1-r0/PyQt5-5.15.1/sip/QtNetwork/qssl.sip"
#include <qssl.h>
#line 39 "/scratch/jenkins-BUILDS-eSDK-2023.1_stable-pipeline-build_async-47_k26_smk_kv_full/build/tmp/work/cortexa72-cortexa53-xilinx-linux/python3-pyqt5/5.15.1-r0/PyQt5-5.15.1/QtNetwork/sipQtNetworkQSslDiffieHellmanParameters.cpp"
#line 26 "sip/QtCore/qiodevice.sip"
#include <qiodevice.h>
#line 42 "/scratch/jenkins-BUILDS-eSDK-2023.1_stable-pipeline-build_async-47_k26_smk_kv_full/build/tmp/work/cortexa72-cortexa53-xilinx-linux/python3-pyqt5/5.15.1-r0/PyQt5-5.15.1/QtNetwork/sipQtNetworkQSslDiffieHellmanParameters.cpp"


PyDoc_STRVAR(doc_QSslDiffieHellmanParameters_swap, "swap(self, QSslDiffieHellmanParameters)");

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

    {
         ::QSslDiffieHellmanParameters* a0;
         ::QSslDiffieHellmanParameters *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QSslDiffieHellmanParameters, &sipCpp, sipType_QSslDiffieHellmanParameters, &a0))
        {
            sipCpp->swap(*a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QSslDiffieHellmanParameters, sipName_swap, doc_QSslDiffieHellmanParameters_swap);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSslDiffieHellmanParameters_defaultParameters, "defaultParameters() -> QSslDiffieHellmanParameters");

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

    {
        if (sipParseArgs(&sipParseErr, sipArgs, ""))
        {
             ::QSslDiffieHellmanParameters*sipRes;

            sipRes = new  ::QSslDiffieHellmanParameters( ::QSslDiffieHellmanParameters::defaultParameters());

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

    sipNoMethod(sipParseErr, sipName_QSslDiffieHellmanParameters, sipName_defaultParameters, doc_QSslDiffieHellmanParameters_defaultParameters);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSslDiffieHellmanParameters_fromEncoded, "fromEncoded(Union[QByteArray, bytes, bytearray], encoding: QSsl.EncodingFormat = QSsl.EncodingFormat.Pem) -> QSslDiffieHellmanParameters\n"
"fromEncoded(QIODevice, encoding: QSsl.EncodingFormat = QSsl.EncodingFormat.Pem) -> QSslDiffieHellmanParameters");

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

    {
        const  ::QByteArray* a0;
        int a0State = 0;
         ::QSsl::EncodingFormat a1 = QSsl::EncodingFormat::Pem;

        static const char *sipKwdList[] = {
            SIP_NULLPTR,
            sipName_encoding,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "J1|E", sipType_QByteArray, &a0, &a0State, sipType_QSsl_EncodingFormat, &a1))
        {
             ::QSslDiffieHellmanParameters*sipRes;

            sipRes = new  ::QSslDiffieHellmanParameters( ::QSslDiffieHellmanParameters::fromEncoded(*a0,a1));
            sipReleaseType(const_cast< ::QByteArray *>(a0),sipType_QByteArray,a0State);

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

    {
         ::QIODevice* a0;
         ::QSsl::EncodingFormat a1 = QSsl::EncodingFormat::Pem;

        static const char *sipKwdList[] = {
            SIP_NULLPTR,
            sipName_encoding,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "J8|E", sipType_QIODevice, &a0, sipType_QSsl_EncodingFormat, &a1))
        {
             ::QSslDiffieHellmanParameters*sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new  ::QSslDiffieHellmanParameters( ::QSslDiffieHellmanParameters::fromEncoded(a0,a1));
            Py_END_ALLOW_THREADS

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

    sipNoMethod(sipParseErr, sipName_QSslDiffieHellmanParameters, sipName_fromEncoded, doc_QSslDiffieHellmanParameters_fromEncoded);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSslDiffieHellmanParameters_isEmpty, "isEmpty(self) -> bool");

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

    {
        const  ::QSslDiffieHellmanParameters *sipCpp;

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

            sipRes = sipCpp->isEmpty();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QSslDiffieHellmanParameters, sipName_isEmpty, doc_QSslDiffieHellmanParameters_isEmpty);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSslDiffieHellmanParameters_isValid, "isValid(self) -> bool");

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

    {
        const  ::QSslDiffieHellmanParameters *sipCpp;

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

            sipRes = sipCpp->isValid();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QSslDiffieHellmanParameters, sipName_isValid, doc_QSslDiffieHellmanParameters_isValid);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSslDiffieHellmanParameters_error, "error(self) -> QSslDiffieHellmanParameters.Error");

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

    {
        const  ::QSslDiffieHellmanParameters *sipCpp;

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

            sipRes = sipCpp->error();

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

    sipNoMethod(sipParseErr, sipName_QSslDiffieHellmanParameters, sipName_error, doc_QSslDiffieHellmanParameters_error);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSslDiffieHellmanParameters_errorString, "errorString(self) -> str");

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

    {
        const  ::QSslDiffieHellmanParameters *sipCpp;

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

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

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

    sipNoMethod(sipParseErr, sipName_QSslDiffieHellmanParameters, sipName_errorString, doc_QSslDiffieHellmanParameters_errorString);

    return SIP_NULLPTR;
}


extern "C" {static PyObject *slot_QSslDiffieHellmanParameters___eq__(PyObject *,PyObject *);}
static PyObject *slot_QSslDiffieHellmanParameters___eq__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QSslDiffieHellmanParameters *sipCpp = reinterpret_cast< ::QSslDiffieHellmanParameters *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QSslDiffieHellmanParameters));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QSslDiffieHellmanParameters* a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J9", sipType_QSslDiffieHellmanParameters, &a0))
        {
            bool sipRes;

            sipRes = operator==((*sipCpp), *a0);

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtNetwork, eq_slot, sipType_QSslDiffieHellmanParameters, sipSelf, sipArg);
}


extern "C" {static PyObject *slot_QSslDiffieHellmanParameters___ne__(PyObject *,PyObject *);}
static PyObject *slot_QSslDiffieHellmanParameters___ne__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QSslDiffieHellmanParameters *sipCpp = reinterpret_cast< ::QSslDiffieHellmanParameters *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QSslDiffieHellmanParameters));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QSslDiffieHellmanParameters* a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J9", sipType_QSslDiffieHellmanParameters, &a0))
        {
            bool sipRes;

            sipRes = operator!=((*sipCpp), *a0);

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtNetwork, ne_slot, sipType_QSslDiffieHellmanParameters, sipSelf, sipArg);
}


extern "C" {static long slot_QSslDiffieHellmanParameters___hash__(PyObject *);}
static long slot_QSslDiffieHellmanParameters___hash__(PyObject *sipSelf)
{
     ::QSslDiffieHellmanParameters *sipCpp = reinterpret_cast< ::QSslDiffieHellmanParameters *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QSslDiffieHellmanParameters));

    if (!sipCpp)
        return 0L;


    {
        {
            long sipRes = 0;

#line 53 "/scratch/jenkins-BUILDS-eSDK-2023.1_stable-pipeline-build_async-47_k26_smk_kv_full/build/tmp/work/cortexa72-cortexa53-xilinx-linux/python3-pyqt5/5.15.1-r0/PyQt5-5.15.1/sip/QtNetwork/qssldiffiehellmanparameters.sip"
        sipRes = qHash(*sipCpp);
#line 342 "/scratch/jenkins-BUILDS-eSDK-2023.1_stable-pipeline-build_async-47_k26_smk_kv_full/build/tmp/work/cortexa72-cortexa53-xilinx-linux/python3-pyqt5/5.15.1-r0/PyQt5-5.15.1/QtNetwork/sipQtNetworkQSslDiffieHellmanParameters.cpp"

            return sipRes;
        }
    }

    return 0;
}


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


extern "C" {static void *array_QSslDiffieHellmanParameters(Py_ssize_t);}
static void *array_QSslDiffieHellmanParameters(Py_ssize_t sipNrElem)
{
    return new  ::QSslDiffieHellmanParameters[sipNrElem];
}


extern "C" {static void assign_QSslDiffieHellmanParameters(void *, SIP_SSIZE_T, void *);}
static void assign_QSslDiffieHellmanParameters(void *sipDst, SIP_SSIZE_T sipDstIdx, void *sipSrc)
{
    reinterpret_cast< ::QSslDiffieHellmanParameters *>(sipDst)[sipDstIdx] = *reinterpret_cast< ::QSslDiffieHellmanParameters *>(sipSrc);
}


extern "C" {static void *copy_QSslDiffieHellmanParameters(const void *, SIP_SSIZE_T);}
static void *copy_QSslDiffieHellmanParameters(const void *sipSrc, SIP_SSIZE_T sipSrcIdx)
{
    return new  ::QSslDiffieHellmanParameters(reinterpret_cast<const  ::QSslDiffieHellmanParameters *>(sipSrc)[sipSrcIdx]);
}


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


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

    {
        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, ""))
        {
            sipCpp = new  ::QSslDiffieHellmanParameters();

            return sipCpp;
        }
    }

    {
        const  ::QSslDiffieHellmanParameters* a0;

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

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's Python slots. */
static sipPySlotDef slots_QSslDiffieHellmanParameters[] = {
    {(void *)slot_QSslDiffieHellmanParameters___eq__, eq_slot},
    {(void *)slot_QSslDiffieHellmanParameters___ne__, ne_slot},
    {(void *)slot_QSslDiffieHellmanParameters___hash__, hash_slot},
    {0, (sipPySlotType)0}
};


static PyMethodDef methods_QSslDiffieHellmanParameters[] = {
    {SIP_MLNAME_CAST(sipName_defaultParameters), meth_QSslDiffieHellmanParameters_defaultParameters, METH_VARARGS, SIP_MLDOC_CAST(doc_QSslDiffieHellmanParameters_defaultParameters)},
    {SIP_MLNAME_CAST(sipName_error), meth_QSslDiffieHellmanParameters_error, METH_VARARGS, SIP_MLDOC_CAST(doc_QSslDiffieHellmanParameters_error)},
    {SIP_MLNAME_CAST(sipName_errorString), meth_QSslDiffieHellmanParameters_errorString, METH_VARARGS, SIP_MLDOC_CAST(doc_QSslDiffieHellmanParameters_errorString)},
    {SIP_MLNAME_CAST(sipName_fromEncoded), SIP_MLMETH_CAST(meth_QSslDiffieHellmanParameters_fromEncoded), METH_VARARGS|METH_KEYWORDS, SIP_MLDOC_CAST(doc_QSslDiffieHellmanParameters_fromEncoded)},
    {SIP_MLNAME_CAST(sipName_isEmpty), meth_QSslDiffieHellmanParameters_isEmpty, METH_VARARGS, SIP_MLDOC_CAST(doc_QSslDiffieHellmanParameters_isEmpty)},
    {SIP_MLNAME_CAST(sipName_isValid), meth_QSslDiffieHellmanParameters_isValid, METH_VARARGS, SIP_MLDOC_CAST(doc_QSslDiffieHellmanParameters_isValid)},
    {SIP_MLNAME_CAST(sipName_swap), meth_QSslDiffieHellmanParameters_swap, METH_VARARGS, SIP_MLDOC_CAST(doc_QSslDiffieHellmanParameters_swap)}
};

static sipEnumMemberDef enummembers_QSslDiffieHellmanParameters[] = {
    {sipName_InvalidInputDataError, static_cast<int>( ::QSslDiffieHellmanParameters::InvalidInputDataError), 125},
    {sipName_NoError, static_cast<int>( ::QSslDiffieHellmanParameters::NoError), 125},
    {sipName_UnsafeParametersError, static_cast<int>( ::QSslDiffieHellmanParameters::UnsafeParametersError), 125},
};

PyDoc_STRVAR(doc_QSslDiffieHellmanParameters, "\1QSslDiffieHellmanParameters()\n"
"QSslDiffieHellmanParameters(QSslDiffieHellmanParameters)");


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


sipClassTypeDef sipTypeDef_QtNetwork_QSslDiffieHellmanParameters = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QSslDiffieHellmanParameters,
        {SIP_NULLPTR},
        &plugin_QSslDiffieHellmanParameters
    },
    {
        sipNameNr_QSslDiffieHellmanParameters,
        {0, 0, 1},
        7, methods_QSslDiffieHellmanParameters,
        3, enummembers_QSslDiffieHellmanParameters,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QSslDiffieHellmanParameters,
    -1,
    sipNameNr_sip_simplewrapper,
    SIP_NULLPTR,
    slots_QSslDiffieHellmanParameters,
    init_type_QSslDiffieHellmanParameters,
    SIP_NULLPTR,
    SIP_NULLPTR,
#if PY_MAJOR_VERSION >= 3
    SIP_NULLPTR,
    SIP_NULLPTR,
#else
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
#endif
    dealloc_QSslDiffieHellmanParameters,
    assign_QSslDiffieHellmanParameters,
    array_QSslDiffieHellmanParameters,
    copy_QSslDiffieHellmanParameters,
    release_QSslDiffieHellmanParameters,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR
};
