/*
 * Interface wrapper code.
 *
 * Generated by SIP 6.14.0
 *
 * Copyright (c) 2024 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 "sipAPIQtXmlPatterns.h"

#line 26 "/build/pyqt5/src/PyQt5-5.15.11/sip/QtXmlPatterns/qxmlresultitems.sip"
#include <qxmlresultitems.h>
#line 29 "/build/pyqt5/src/PyQt5-5.15.11/build/QtXmlPatterns/sipQtXmlPatternsQXmlResultItems.cpp"

#line 117 "/build/pyqt5/src/PyQt5-5.15.11/sip/QtXmlPatterns/qabstractxmlnodemodel.sip"
#include <qabstractxmlnodemodel.h>
#line 33 "/build/pyqt5/src/PyQt5-5.15.11/build/QtXmlPatterns/sipQtXmlPatternsQXmlResultItems.cpp"


class sipQXmlResultItems : public ::QXmlResultItems
{
public:
    sipQXmlResultItems();
    ~sipQXmlResultItems();

public:
    sipSimpleWrapper *sipPySelf;

private:
    sipQXmlResultItems(const sipQXmlResultItems &);
    sipQXmlResultItems &operator = (const sipQXmlResultItems &);
};

sipQXmlResultItems::sipQXmlResultItems(): ::QXmlResultItems(), sipPySelf(SIP_NULLPTR)
{
}

sipQXmlResultItems::~sipQXmlResultItems()
{
    sipInstanceDestroyedEx(&sipPySelf);
}


PyDoc_STRVAR(doc_QXmlResultItems_hasError, "hasError(self) -> bool");

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

    {
        const ::QXmlResultItems *sipCpp;

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

            sipRes = sipCpp->hasError();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QXmlResultItems, sipName_hasError, doc_QXmlResultItems_hasError);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlResultItems_next, "next(self) -> QXmlItem");

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

    {
        ::QXmlResultItems *sipCpp;

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

            sipRes = new ::QXmlItem(sipCpp->next());

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

    sipNoMethod(sipParseErr, sipName_QXmlResultItems, sipName_next, doc_QXmlResultItems_next);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlResultItems_current, "current(self) -> QXmlItem");

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

    {
        const ::QXmlResultItems *sipCpp;

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

            sipRes = new ::QXmlItem(sipCpp->current());

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

    sipNoMethod(sipParseErr, sipName_QXmlResultItems, sipName_current, doc_QXmlResultItems_current);

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_QXmlResultItems(void *, int);}
static void release_QXmlResultItems(void *sipCppV, int sipState)
{
    if (sipState & SIP_DERIVED_CLASS)
        delete reinterpret_cast<sipQXmlResultItems *>(sipCppV);
    else
        delete reinterpret_cast< ::QXmlResultItems *>(sipCppV);
}


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


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


extern "C" {static void dealloc_QXmlResultItems(sipSimpleWrapper *);}
static void dealloc_QXmlResultItems(sipSimpleWrapper *sipSelf)
{
    if (sipIsDerivedClass(sipSelf))
        reinterpret_cast<sipQXmlResultItems *>(sipGetAddress(sipSelf))->sipPySelf = SIP_NULLPTR;

    if (sipIsOwnedByPython(sipSelf))
    {
        release_QXmlResultItems(sipGetAddress(sipSelf), sipIsDerivedClass(sipSelf));
    }
}


extern "C" {static void *init_type_QXmlResultItems(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_QXmlResultItems(sipSimpleWrapper *sipSelf, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **, PyObject **sipParseErr)
{
    sipQXmlResultItems *sipCpp = SIP_NULLPTR;

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

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


static PyMethodDef methods_QXmlResultItems[] = {
    {sipName_current, meth_QXmlResultItems_current, METH_VARARGS, doc_QXmlResultItems_current},
    {sipName_hasError, meth_QXmlResultItems_hasError, METH_VARARGS, doc_QXmlResultItems_hasError},
    {sipName_next, meth_QXmlResultItems_next, METH_VARARGS, doc_QXmlResultItems_next}
};

PyDoc_STRVAR(doc_QXmlResultItems, "\1QXmlResultItems()");


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


sipClassTypeDef sipTypeDef_QtXmlPatterns_QXmlResultItems = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QXmlResultItems,
        SIP_NULLPTR,
        &plugin_QXmlResultItems,
    },
    {
        sipNameNr_QXmlResultItems,
        {0, 0, 1},
        3, methods_QXmlResultItems,
        0, SIP_NULLPTR,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QXmlResultItems,
    -1,
    sipNameNr_sip_simplewrapper,
    SIP_NULLPTR,
    SIP_NULLPTR,
    init_type_QXmlResultItems,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QXmlResultItems,
    SIP_NULLPTR,
    array_QXmlResultItems,
    SIP_NULLPTR,
    release_QXmlResultItems,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    array_delete_QXmlResultItems,
    sizeof (::QXmlResultItems),
};
