/*
 * 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 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/qhstspolicy.sip"
#include <qhstspolicy.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/sipQtNetworkQHstsPolicy.cpp"

#line 360 "sip/QtCore/qdatetime.sip"
#include <qdatetime.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/sipQtNetworkQHstsPolicy.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/qhstspolicy.sip"
#include <qhstspolicy.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/sipQtNetworkQHstsPolicy.cpp"
#line 27 "sip/QtCore/qstring.sip"
#include <qstring.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/sipQtNetworkQHstsPolicy.cpp"
#line 96 "sip/QtCore/qurl.sip"
#include <qurl.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/sipQtNetworkQHstsPolicy.cpp"
#line 96 "sip/QtCore/qurl.sip"
#include <qurl.h>
#line 45 "/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/sipQtNetworkQHstsPolicy.cpp"


PyDoc_STRVAR(doc_QHstsPolicy_swap, "swap(self, QHstsPolicy)");

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

    {
         ::QHstsPolicy* a0;
         ::QHstsPolicy *sipCpp;

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

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QHstsPolicy, sipName_swap, doc_QHstsPolicy_swap);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QHstsPolicy_setHost, "setHost(self, str, mode: QUrl.ParsingMode = QUrl.DecodedMode)");

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

    {
        const  ::QString* a0;
        int a0State = 0;
         ::QUrl::ParsingMode a1 = QUrl::DecodedMode;
         ::QHstsPolicy *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ1|E", &sipSelf, sipType_QHstsPolicy, &sipCpp, sipType_QString,&a0, &a0State, sipType_QUrl_ParsingMode, &a1))
        {
            sipCpp->setHost(*a0,a1);
            sipReleaseType(const_cast< ::QString *>(a0),sipType_QString,a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QHstsPolicy, sipName_setHost, doc_QHstsPolicy_setHost);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QHstsPolicy_host, "host(self, options: Union[QUrl.ComponentFormattingOptions, QUrl.ComponentFormattingOption] = QUrl.ComponentFormattingOption.FullyDecoded) -> str");

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

    {
         ::QUrl::ComponentFormattingOptions a0def = QUrl::ComponentFormattingOption::FullyDecoded;
         ::QUrl::ComponentFormattingOptions* a0 = &a0def;
        int a0State = 0;
        const  ::QHstsPolicy *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "B|J1", &sipSelf, sipType_QHstsPolicy, &sipCpp, sipType_QUrl_ComponentFormattingOptions, &a0, &a0State))
        {
             ::QString*sipRes;

            sipRes = new  ::QString(sipCpp->host(*a0));
            sipReleaseType(a0,sipType_QUrl_ComponentFormattingOptions,a0State);

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

    sipNoMethod(sipParseErr, sipName_QHstsPolicy, sipName_host, doc_QHstsPolicy_host);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QHstsPolicy_setExpiry, "setExpiry(self, Union[QDateTime, datetime.datetime])");

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

    {
        const  ::QDateTime* a0;
        int a0State = 0;
         ::QHstsPolicy *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QHstsPolicy, &sipCpp, sipType_QDateTime, &a0, &a0State))
        {
            sipCpp->setExpiry(*a0);
            sipReleaseType(const_cast< ::QDateTime *>(a0),sipType_QDateTime,a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QHstsPolicy, sipName_setExpiry, doc_QHstsPolicy_setExpiry);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QHstsPolicy_expiry, "expiry(self) -> QDateTime");

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

    {
        const  ::QHstsPolicy *sipCpp;

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

            sipRes = new  ::QDateTime(sipCpp->expiry());

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

    sipNoMethod(sipParseErr, sipName_QHstsPolicy, sipName_expiry, doc_QHstsPolicy_expiry);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QHstsPolicy_setIncludesSubDomains, "setIncludesSubDomains(self, bool)");

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

    {
        bool a0;
         ::QHstsPolicy *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bb", &sipSelf, sipType_QHstsPolicy, &sipCpp, &a0))
        {
            sipCpp->setIncludesSubDomains(a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QHstsPolicy, sipName_setIncludesSubDomains, doc_QHstsPolicy_setIncludesSubDomains);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QHstsPolicy_includesSubDomains, "includesSubDomains(self) -> bool");

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

    {
        const  ::QHstsPolicy *sipCpp;

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

            sipRes = sipCpp->includesSubDomains();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QHstsPolicy, sipName_includesSubDomains, doc_QHstsPolicy_includesSubDomains);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QHstsPolicy_isExpired, "isExpired(self) -> bool");

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

    {
        const  ::QHstsPolicy *sipCpp;

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

            sipRes = sipCpp->isExpired();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QHstsPolicy, sipName_isExpired, doc_QHstsPolicy_isExpired);

    return SIP_NULLPTR;
}


extern "C" {static PyObject *slot_QHstsPolicy___eq__(PyObject *,PyObject *);}
static PyObject *slot_QHstsPolicy___eq__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QHstsPolicy *sipCpp = reinterpret_cast< ::QHstsPolicy *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QHstsPolicy));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QHstsPolicy* a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J9", sipType_QHstsPolicy, &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_QHstsPolicy, sipSelf, sipArg);
}


extern "C" {static PyObject *slot_QHstsPolicy___ne__(PyObject *,PyObject *);}
static PyObject *slot_QHstsPolicy___ne__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QHstsPolicy *sipCpp = reinterpret_cast< ::QHstsPolicy *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QHstsPolicy));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QHstsPolicy* a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J9", sipType_QHstsPolicy, &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_QHstsPolicy, sipSelf, sipArg);
}


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


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


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


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


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


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

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

            return sipCpp;
        }
    }

    {
        const  ::QDateTime* a0;
        int a0State = 0;
         ::QHstsPolicy::PolicyFlags* a1;
        int a1State = 0;
        const  ::QString* a2;
        int a2State = 0;
         ::QUrl::ParsingMode a3 = QUrl::DecodedMode;

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

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, sipKwdList, sipUnused, "J1J1J1|E", sipType_QDateTime, &a0, &a0State, sipType_QHstsPolicy_PolicyFlags, &a1, &a1State, sipType_QString,&a2, &a2State, sipType_QUrl_ParsingMode, &a3))
        {
            sipCpp = new  ::QHstsPolicy(*a0,*a1,*a2,a3);
            sipReleaseType(const_cast< ::QDateTime *>(a0),sipType_QDateTime,a0State);
            sipReleaseType(a1,sipType_QHstsPolicy_PolicyFlags,a1State);
            sipReleaseType(const_cast< ::QString *>(a2),sipType_QString,a2State);

            return sipCpp;
        }
    }

    {
        const  ::QHstsPolicy* a0;

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

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's Python slots. */
static sipPySlotDef slots_QHstsPolicy[] = {
    {(void *)slot_QHstsPolicy___eq__, eq_slot},
    {(void *)slot_QHstsPolicy___ne__, ne_slot},
    {0, (sipPySlotType)0}
};


static PyMethodDef methods_QHstsPolicy[] = {
    {SIP_MLNAME_CAST(sipName_expiry), meth_QHstsPolicy_expiry, METH_VARARGS, SIP_MLDOC_CAST(doc_QHstsPolicy_expiry)},
    {SIP_MLNAME_CAST(sipName_host), SIP_MLMETH_CAST(meth_QHstsPolicy_host), METH_VARARGS|METH_KEYWORDS, SIP_MLDOC_CAST(doc_QHstsPolicy_host)},
    {SIP_MLNAME_CAST(sipName_includesSubDomains), meth_QHstsPolicy_includesSubDomains, METH_VARARGS, SIP_MLDOC_CAST(doc_QHstsPolicy_includesSubDomains)},
    {SIP_MLNAME_CAST(sipName_isExpired), meth_QHstsPolicy_isExpired, METH_VARARGS, SIP_MLDOC_CAST(doc_QHstsPolicy_isExpired)},
    {SIP_MLNAME_CAST(sipName_setExpiry), meth_QHstsPolicy_setExpiry, METH_VARARGS, SIP_MLDOC_CAST(doc_QHstsPolicy_setExpiry)},
    {SIP_MLNAME_CAST(sipName_setHost), SIP_MLMETH_CAST(meth_QHstsPolicy_setHost), METH_VARARGS|METH_KEYWORDS, SIP_MLDOC_CAST(doc_QHstsPolicy_setHost)},
    {SIP_MLNAME_CAST(sipName_setIncludesSubDomains), meth_QHstsPolicy_setIncludesSubDomains, METH_VARARGS, SIP_MLDOC_CAST(doc_QHstsPolicy_setIncludesSubDomains)},
    {SIP_MLNAME_CAST(sipName_swap), meth_QHstsPolicy_swap, METH_VARARGS, SIP_MLDOC_CAST(doc_QHstsPolicy_swap)}
};

static sipEnumMemberDef enummembers_QHstsPolicy[] = {
    {sipName_IncludeSubDomains, static_cast<int>( ::QHstsPolicy::IncludeSubDomains), 28},
};

PyDoc_STRVAR(doc_QHstsPolicy, "\1QHstsPolicy()\n"
"QHstsPolicy(Union[QDateTime, datetime.datetime], Union[QHstsPolicy.PolicyFlags, QHstsPolicy.PolicyFlag], str, mode: QUrl.ParsingMode = QUrl.DecodedMode)\n"
"QHstsPolicy(QHstsPolicy)");


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


sipClassTypeDef sipTypeDef_QtNetwork_QHstsPolicy = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QHstsPolicy,
        {SIP_NULLPTR},
        &plugin_QHstsPolicy
    },
    {
        sipNameNr_QHstsPolicy,
        {0, 0, 1},
        8, methods_QHstsPolicy,
        1, enummembers_QHstsPolicy,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QHstsPolicy,
    -1,
    sipNameNr_sip_simplewrapper,
    SIP_NULLPTR,
    slots_QHstsPolicy,
    init_type_QHstsPolicy,
    SIP_NULLPTR,
    SIP_NULLPTR,
#if PY_MAJOR_VERSION >= 3
    SIP_NULLPTR,
    SIP_NULLPTR,
#else
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
#endif
    dealloc_QHstsPolicy,
    assign_QHstsPolicy,
    array_QHstsPolicy,
    copy_QHstsPolicy,
    release_QHstsPolicy,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR
};
