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

#line 91 "/build/pyqt6/src/PyQt6-6.4.0/sip/QtCore/qversionnumber.sip"
#include <qversionnumber.h>
#line 29 "/build/pyqt6/src/PyQt6-6.4.0/build/QtCore/sipQtCoreQTypeRevision.cpp"



PyDoc_STRVAR(doc_QTypeRevision_zero, "zero() -> QTypeRevision");

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

    {
        if (sipParseArgs(&sipParseErr, sipArgs, "C", &sipSelf))
        {
             ::QTypeRevision*sipRes;

            sipRes = new  ::QTypeRevision( ::QTypeRevision::zero());

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

    sipNoMethod(sipParseErr, sipName_QTypeRevision, sipName_zero, doc_QTypeRevision_zero);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTypeRevision_hasMajorVersion, "hasMajorVersion(self) -> bool");

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

    {
        const  ::QTypeRevision *sipCpp;

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

            sipRes = sipCpp->hasMajorVersion();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTypeRevision, sipName_hasMajorVersion, doc_QTypeRevision_hasMajorVersion);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTypeRevision_majorVersion, "majorVersion(self) -> int");

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

    {
        const  ::QTypeRevision *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTypeRevision, &sipCpp))
        {
             ::quint8 sipRes;

            sipRes = sipCpp->majorVersion();

            return PyLong_FromUnsignedLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTypeRevision, sipName_majorVersion, doc_QTypeRevision_majorVersion);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTypeRevision_hasMinorVersion, "hasMinorVersion(self) -> bool");

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

    {
        const  ::QTypeRevision *sipCpp;

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

            sipRes = sipCpp->hasMinorVersion();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTypeRevision, sipName_hasMinorVersion, doc_QTypeRevision_hasMinorVersion);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTypeRevision_minorVersion, "minorVersion(self) -> int");

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

    {
        const  ::QTypeRevision *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTypeRevision, &sipCpp))
        {
             ::quint8 sipRes;

            sipRes = sipCpp->minorVersion();

            return PyLong_FromUnsignedLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTypeRevision, sipName_minorVersion, doc_QTypeRevision_minorVersion);

    return SIP_NULLPTR;
}


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

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

    {
        const  ::QTypeRevision *sipCpp;

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

            sipRes = sipCpp->isValid();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTypeRevision, sipName_isValid, doc_QTypeRevision_isValid);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTypeRevision_toEncodedVersion, "toEncodedVersion(self) -> int");

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

    {
        const  ::QTypeRevision *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTypeRevision, &sipCpp))
        {
            unsigned short sipRes = 0;

#line 104 "/build/pyqt6/src/PyQt6-6.4.0/sip/QtCore/qversionnumber.sip"
        sipRes = sipCpp->toEncodedVersion<unsigned short>();
#line 210 "/build/pyqt6/src/PyQt6-6.4.0/build/QtCore/sipQtCoreQTypeRevision.cpp"

            return PyLong_FromUnsignedLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTypeRevision, sipName_toEncodedVersion, doc_QTypeRevision_toEncodedVersion);

    return SIP_NULLPTR;
}


extern "C" {static PyObject *slot_QTypeRevision___eq__(PyObject *,PyObject *);}
static PyObject *slot_QTypeRevision___eq__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QTypeRevision *sipCpp = reinterpret_cast< ::QTypeRevision *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QTypeRevision));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
         ::QTypeRevision* a0;

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

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

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtCore, eq_slot, sipType_QTypeRevision, sipSelf, sipArg);
}


extern "C" {static PyObject *slot_QTypeRevision___ne__(PyObject *,PyObject *);}
static PyObject *slot_QTypeRevision___ne__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QTypeRevision *sipCpp = reinterpret_cast< ::QTypeRevision *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QTypeRevision));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
         ::QTypeRevision* a0;

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

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

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtCore, ne_slot, sipType_QTypeRevision, sipSelf, sipArg);
}


extern "C" {static PyObject *slot_QTypeRevision___lt__(PyObject *,PyObject *);}
static PyObject *slot_QTypeRevision___lt__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QTypeRevision *sipCpp = reinterpret_cast< ::QTypeRevision *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QTypeRevision));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
         ::QTypeRevision* a0;

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

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

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtCore, lt_slot, sipType_QTypeRevision, sipSelf, sipArg);
}


extern "C" {static PyObject *slot_QTypeRevision___le__(PyObject *,PyObject *);}
static PyObject *slot_QTypeRevision___le__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QTypeRevision *sipCpp = reinterpret_cast< ::QTypeRevision *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QTypeRevision));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
         ::QTypeRevision* a0;

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

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

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtCore, le_slot, sipType_QTypeRevision, sipSelf, sipArg);
}


extern "C" {static PyObject *slot_QTypeRevision___gt__(PyObject *,PyObject *);}
static PyObject *slot_QTypeRevision___gt__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QTypeRevision *sipCpp = reinterpret_cast< ::QTypeRevision *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QTypeRevision));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
         ::QTypeRevision* a0;

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

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

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtCore, gt_slot, sipType_QTypeRevision, sipSelf, sipArg);
}


extern "C" {static PyObject *slot_QTypeRevision___ge__(PyObject *,PyObject *);}
static PyObject *slot_QTypeRevision___ge__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QTypeRevision *sipCpp = reinterpret_cast< ::QTypeRevision *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QTypeRevision));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
         ::QTypeRevision* a0;

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

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

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtCore, ge_slot, sipType_QTypeRevision, sipSelf, sipArg);
}


extern "C" {static Py_hash_t slot_QTypeRevision___hash__(PyObject *);}
static Py_hash_t slot_QTypeRevision___hash__(PyObject *sipSelf)
{
     ::QTypeRevision *sipCpp = reinterpret_cast< ::QTypeRevision *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QTypeRevision));

    if (!sipCpp)
        return 0;


    {
        {
            Py_hash_t sipRes = 0;

#line 109 "/build/pyqt6/src/PyQt6-6.4.0/sip/QtCore/qversionnumber.sip"
        sipRes = qHash(*sipCpp);
#line 429 "/build/pyqt6/src/PyQt6-6.4.0/build/QtCore/sipQtCoreQTypeRevision.cpp"

            return sipRes;
        }
    }

    return 0;
}


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


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


extern "C" {static void array_delete_QTypeRevision(void *);}
static void array_delete_QTypeRevision(void *sipCpp)
{
    delete[] reinterpret_cast< ::QTypeRevision *>(sipCpp);
}


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


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


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


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

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

            return sipCpp;
        }
    }

    {
        const  ::QTypeRevision* a0;

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

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's Python slots. */
static sipPySlotDef slots_QTypeRevision[] = {
    {(void *)slot_QTypeRevision___eq__, eq_slot},
    {(void *)slot_QTypeRevision___ne__, ne_slot},
    {(void *)slot_QTypeRevision___lt__, lt_slot},
    {(void *)slot_QTypeRevision___le__, le_slot},
    {(void *)slot_QTypeRevision___gt__, gt_slot},
    {(void *)slot_QTypeRevision___ge__, ge_slot},
    {(void *)slot_QTypeRevision___hash__, hash_slot},
    {0, (sipPySlotType)0}
};


static PyMethodDef methods_QTypeRevision[] = {
    {sipName_hasMajorVersion, meth_QTypeRevision_hasMajorVersion, METH_VARARGS, doc_QTypeRevision_hasMajorVersion},
    {sipName_hasMinorVersion, meth_QTypeRevision_hasMinorVersion, METH_VARARGS, doc_QTypeRevision_hasMinorVersion},
    {sipName_isValid, meth_QTypeRevision_isValid, METH_VARARGS, doc_QTypeRevision_isValid},
    {sipName_majorVersion, meth_QTypeRevision_majorVersion, METH_VARARGS, doc_QTypeRevision_majorVersion},
    {sipName_minorVersion, meth_QTypeRevision_minorVersion, METH_VARARGS, doc_QTypeRevision_minorVersion},
    {sipName_toEncodedVersion, meth_QTypeRevision_toEncodedVersion, METH_VARARGS, doc_QTypeRevision_toEncodedVersion},
    {sipName_zero, meth_QTypeRevision_zero, METH_VARARGS, doc_QTypeRevision_zero}
};

PyDoc_STRVAR(doc_QTypeRevision, "\1QTypeRevision()\n"
"QTypeRevision(QTypeRevision)");


sipClassTypeDef sipTypeDef_QtCore_QTypeRevision = {
    {
        SIP_NULLPTR,
        SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QTypeRevision,
        SIP_NULLPTR,
        SIP_NULLPTR
    },
    {
        sipNameNr_QTypeRevision,
        {0, 0, 1},
        7, methods_QTypeRevision,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QTypeRevision,
    -1,
    sipNameNr_PyQt6_sip_simplewrapper,
    SIP_NULLPTR,
    slots_QTypeRevision,
    init_type_QTypeRevision,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QTypeRevision,
    assign_QTypeRevision,
    array_QTypeRevision,
    copy_QTypeRevision,
    release_QTypeRevision,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    array_delete_QTypeRevision,
    sizeof ( ::QTypeRevision),
};
