/*
 * Interface wrapper code.
 *
 * Generated by SIP 6.6.2
 *
 * Copyright (c) 2022 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 "sipAPIQtXml.h"

#line 50 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtXml/qxml.sip"
#include <qxml.h>
#line 29 "/build/pyqt5/src/PyQt5-5.15.7/build/QtXml/sipQtXmlQXmlAttributes.cpp"

#line 27 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qstring.sip"
#include <qstring.h>
#line 33 "/build/pyqt5/src/PyQt5-5.15.7/build/QtXml/sipQtXmlQXmlAttributes.cpp"


class sipQXmlAttributes : public  ::QXmlAttributes
{
public:
    sipQXmlAttributes();
    sipQXmlAttributes(const  ::QXmlAttributes&);
    ~sipQXmlAttributes();

public:
    sipSimpleWrapper *sipPySelf;

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

sipQXmlAttributes::sipQXmlAttributes():  ::QXmlAttributes(), sipPySelf(SIP_NULLPTR)
{
}

sipQXmlAttributes::sipQXmlAttributes(const  ::QXmlAttributes& a0):  ::QXmlAttributes(a0), sipPySelf(SIP_NULLPTR)
{
}

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


PyDoc_STRVAR(doc_QXmlAttributes_index, "index(self, str) -> int\n"
"index(self, str, str) -> int");

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

    {
        const  ::QString* a0;
        int a0State = 0;
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QXmlAttributes, &sipCpp, sipType_QString, &a0, &a0State))
        {
            int sipRes;

            sipRes = sipCpp->index(*a0);
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);

            return PyLong_FromLong(sipRes);
        }
    }

    {
        const  ::QString* a0;
        int a0State = 0;
        const  ::QString* a1;
        int a1State = 0;
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J1", &sipSelf, sipType_QXmlAttributes, &sipCpp, sipType_QString, &a0, &a0State, sipType_QString, &a1, &a1State))
        {
            int sipRes;

            sipRes = sipCpp->index(*a0,*a1);
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);
            sipReleaseType(const_cast< ::QString *>(a1), sipType_QString, a1State);

            return PyLong_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QXmlAttributes, sipName_index, doc_QXmlAttributes_index);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlAttributes_length, "length(self) -> int");

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

    {
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QXmlAttributes, &sipCpp))
        {
            int sipRes;

            sipRes = sipCpp->length();

            return PyLong_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QXmlAttributes, sipName_length, doc_QXmlAttributes_length);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlAttributes_localName, "localName(self, int) -> str");

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

    {
        int a0;
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bi", &sipSelf, sipType_QXmlAttributes, &sipCpp, &a0))
        {
             ::QString*sipRes;

            sipRes = new  ::QString(sipCpp->localName(a0));

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

    sipNoMethod(sipParseErr, sipName_QXmlAttributes, sipName_localName, doc_QXmlAttributes_localName);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlAttributes_qName, "qName(self, int) -> str");

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

    {
        int a0;
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bi", &sipSelf, sipType_QXmlAttributes, &sipCpp, &a0))
        {
             ::QString*sipRes;

            sipRes = new  ::QString(sipCpp->qName(a0));

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

    sipNoMethod(sipParseErr, sipName_QXmlAttributes, sipName_qName, doc_QXmlAttributes_qName);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlAttributes_uri, "uri(self, int) -> str");

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

    {
        int a0;
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bi", &sipSelf, sipType_QXmlAttributes, &sipCpp, &a0))
        {
             ::QString*sipRes;

            sipRes = new  ::QString(sipCpp->uri(a0));

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

    sipNoMethod(sipParseErr, sipName_QXmlAttributes, sipName_uri, doc_QXmlAttributes_uri);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlAttributes_type, "type(self, int) -> str\n"
"type(self, str) -> str\n"
"type(self, str, str) -> str");

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

    {
        int a0;
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bi", &sipSelf, sipType_QXmlAttributes, &sipCpp, &a0))
        {
             ::QString*sipRes;

            sipRes = new  ::QString(sipCpp->type(a0));

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

    {
        const  ::QString* a0;
        int a0State = 0;
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QXmlAttributes, &sipCpp, sipType_QString, &a0, &a0State))
        {
             ::QString*sipRes;

            sipRes = new  ::QString(sipCpp->type(*a0));
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);

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

    {
        const  ::QString* a0;
        int a0State = 0;
        const  ::QString* a1;
        int a1State = 0;
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J1", &sipSelf, sipType_QXmlAttributes, &sipCpp, sipType_QString, &a0, &a0State, sipType_QString, &a1, &a1State))
        {
             ::QString*sipRes;

            sipRes = new  ::QString(sipCpp->type(*a0,*a1));
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);
            sipReleaseType(const_cast< ::QString *>(a1), sipType_QString, a1State);

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

    sipNoMethod(sipParseErr, sipName_QXmlAttributes, sipName_type, doc_QXmlAttributes_type);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlAttributes_value, "value(self, int) -> str\n"
"value(self, str) -> str\n"
"value(self, str, str) -> str");

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

    {
        int a0;
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bi", &sipSelf, sipType_QXmlAttributes, &sipCpp, &a0))
        {
             ::QString*sipRes;

            sipRes = new  ::QString(sipCpp->value(a0));

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

    {
        const  ::QString* a0;
        int a0State = 0;
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QXmlAttributes, &sipCpp, sipType_QString, &a0, &a0State))
        {
             ::QString*sipRes;

            sipRes = new  ::QString(sipCpp->value(*a0));
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);

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

    {
        const  ::QString* a0;
        int a0State = 0;
        const  ::QString* a1;
        int a1State = 0;
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J1", &sipSelf, sipType_QXmlAttributes, &sipCpp, sipType_QString, &a0, &a0State, sipType_QString, &a1, &a1State))
        {
             ::QString*sipRes;

            sipRes = new  ::QString(sipCpp->value(*a0,*a1));
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);
            sipReleaseType(const_cast< ::QString *>(a1), sipType_QString, a1State);

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

    sipNoMethod(sipParseErr, sipName_QXmlAttributes, sipName_value, doc_QXmlAttributes_value);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlAttributes_clear, "clear(self)");

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

    {
         ::QXmlAttributes *sipCpp;

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

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QXmlAttributes, sipName_clear, doc_QXmlAttributes_clear);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlAttributes_append, "append(self, str, str, str, str)");

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

    {
        const  ::QString* a0;
        int a0State = 0;
        const  ::QString* a1;
        int a1State = 0;
        const  ::QString* a2;
        int a2State = 0;
        const  ::QString* a3;
        int a3State = 0;
         ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J1J1J1", &sipSelf, sipType_QXmlAttributes, &sipCpp, sipType_QString, &a0, &a0State, sipType_QString, &a1, &a1State, sipType_QString, &a2, &a2State, sipType_QString, &a3, &a3State))
        {
            sipCpp->append(*a0,*a1,*a2,*a3);
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);
            sipReleaseType(const_cast< ::QString *>(a1), sipType_QString, a1State);
            sipReleaseType(const_cast< ::QString *>(a2), sipType_QString, a2State);
            sipReleaseType(const_cast< ::QString *>(a3), sipType_QString, a3State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QXmlAttributes, sipName_append, doc_QXmlAttributes_append);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlAttributes_count, "count(self) -> int");

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

    {
        const  ::QXmlAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QXmlAttributes, &sipCpp))
        {
            int sipRes;

            sipRes = sipCpp->count();

            return PyLong_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QXmlAttributes, sipName_count, doc_QXmlAttributes_count);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QXmlAttributes_swap, "swap(self, QXmlAttributes)");

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

    {
         ::QXmlAttributes* a0;
         ::QXmlAttributes *sipCpp;

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

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QXmlAttributes, sipName_swap, doc_QXmlAttributes_swap);

    return SIP_NULLPTR;
}


extern "C" {static Py_ssize_t slot_QXmlAttributes___len__(PyObject *);}
static Py_ssize_t slot_QXmlAttributes___len__(PyObject *sipSelf)
{
     ::QXmlAttributes *sipCpp = reinterpret_cast< ::QXmlAttributes *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QXmlAttributes));

    if (!sipCpp)
        return 0;


    {
        {
            Py_ssize_t sipRes = 0;

#line 1 "Auto-generated"
            sipRes = (Py_ssize_t)sipCpp->count();
#line 494 "/build/pyqt5/src/PyQt5-5.15.7/build/QtXml/sipQtXmlQXmlAttributes.cpp"

            return sipRes;
        }
    }

    return 0;
}


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


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


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


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


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


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

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


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

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

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    {
        const  ::QXmlAttributes* a0;

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

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's Python slots. */
static sipPySlotDef slots_QXmlAttributes[] = {
    {(void *)slot_QXmlAttributes___len__, len_slot},
    {0, (sipPySlotType)0}
};


static PyMethodDef methods_QXmlAttributes[] = {
    {sipName_append, meth_QXmlAttributes_append, METH_VARARGS, doc_QXmlAttributes_append},
    {sipName_clear, meth_QXmlAttributes_clear, METH_VARARGS, doc_QXmlAttributes_clear},
    {sipName_count, meth_QXmlAttributes_count, METH_VARARGS, doc_QXmlAttributes_count},
    {sipName_index, meth_QXmlAttributes_index, METH_VARARGS, doc_QXmlAttributes_index},
    {sipName_length, meth_QXmlAttributes_length, METH_VARARGS, doc_QXmlAttributes_length},
    {sipName_localName, meth_QXmlAttributes_localName, METH_VARARGS, doc_QXmlAttributes_localName},
    {sipName_qName, meth_QXmlAttributes_qName, METH_VARARGS, doc_QXmlAttributes_qName},
    {sipName_swap, meth_QXmlAttributes_swap, METH_VARARGS, doc_QXmlAttributes_swap},
    {sipName_type, meth_QXmlAttributes_type, METH_VARARGS, doc_QXmlAttributes_type},
    {sipName_uri, meth_QXmlAttributes_uri, METH_VARARGS, doc_QXmlAttributes_uri},
    {sipName_value, meth_QXmlAttributes_value, METH_VARARGS, doc_QXmlAttributes_value}
};

PyDoc_STRVAR(doc_QXmlAttributes, "\1QXmlAttributes()\n"
"QXmlAttributes(QXmlAttributes)");


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


sipClassTypeDef sipTypeDef_QtXml_QXmlAttributes = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QXmlAttributes,
        SIP_NULLPTR,
        &plugin_QXmlAttributes
    },
    {
        sipNameNr_QXmlAttributes,
        {0, 0, 1},
        11, methods_QXmlAttributes,
        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_QXmlAttributes,
    -1,
    sipNameNr_sip_simplewrapper,
    SIP_NULLPTR,
    slots_QXmlAttributes,
    init_type_QXmlAttributes,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QXmlAttributes,
    assign_QXmlAttributes,
    array_QXmlAttributes,
    copy_QXmlAttributes,
    release_QXmlAttributes,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    array_delete_QXmlAttributes,
    sizeof ( ::QXmlAttributes),
};
