/*
 * Interface wrapper code.
 *
 * Generated by SIP 4.19.16
 *
 *     Copyright: (c) 2018 by Total Control Software
 *     License:   wxWindows License
 */

#include "sipAPI_propgrid.h"

        #include <wx/propgrid/propgridpagestate.h>

        #include <wx/propgrid/property.h>
        #include <wx/propgrid/propgridpagestate.h>


PyDoc_STRVAR(doc_wxPropertyGridIteratorBase_Assign, "Assign(it)");

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

    {
        const  ::wxPropertyGridIteratorBase* it;
         ::wxPropertyGridIteratorBase *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9", &sipSelf, sipType_wxPropertyGridIteratorBase, &sipCpp, sipType_wxPropertyGridIteratorBase, &it))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp->Assign(*it);
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_PropertyGridIteratorBase, sipName_Assign, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxPropertyGridIteratorBase_AtEnd, "AtEnd() -> bool");

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

    {
        const  ::wxPropertyGridIteratorBase *sipCpp;

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

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->AtEnd();
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            return PyBool_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_PropertyGridIteratorBase, sipName_AtEnd, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxPropertyGridIteratorBase_GetProperty, "GetProperty() -> PGProperty\n"
"\n"
"Get current property.");

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

    {
        const  ::wxPropertyGridIteratorBase *sipCpp;

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

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->GetProperty();
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            return sipConvertFromType(sipRes,sipType_wxPGProperty,SIP_NULLPTR);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_PropertyGridIteratorBase, sipName_GetProperty, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxPropertyGridIteratorBase_Init, "Init(state, flags, property, dir=1)\n"
"Init(state, flags, startPos=wx.TOP, dir=0)\n"
"");

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

    {
         ::wxPropertyGridPageState* state;
        int flags;
         ::wxPGProperty* property;
        int dir = 1;
         ::wxPropertyGridIteratorBase *sipCpp;

        static const char *sipKwdList[] = {
            sipName_state,
            sipName_flags,
            sipName_property,
            sipName_dir,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ8iJ8|i", &sipSelf, sipType_wxPropertyGridIteratorBase, &sipCpp, sipType_wxPropertyGridPageState, &state, &flags, sipType_wxPGProperty, &property, &dir))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp->Init(state,flags,property,dir);
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
         ::wxPropertyGridPageState* state;
        int flags;
        int startPos = wxTOP;
        int dir = 0;
         ::wxPropertyGridIteratorBase *sipCpp;

        static const char *sipKwdList[] = {
            sipName_state,
            sipName_flags,
            sipName_startPos,
            sipName_dir,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ8i|ii", &sipSelf, sipType_wxPropertyGridIteratorBase, &sipCpp, sipType_wxPropertyGridPageState, &state, &flags, &startPos, &dir))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp->Init(state,flags,startPos,dir);
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_PropertyGridIteratorBase, sipName_Init, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxPropertyGridIteratorBase_Next, "Next(iterateChildren=True)\n"
"\n"
"Iterate to the next property.");

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

    {
        bool iterateChildren = 1;
         ::wxPropertyGridIteratorBase *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "B|b", &sipSelf, sipType_wxPropertyGridIteratorBase, &sipCpp, &iterateChildren))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp->Next(iterateChildren);
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_PropertyGridIteratorBase, sipName_Next, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxPropertyGridIteratorBase_Prev, "Prev()\n"
"\n"
"Iterate to the previous property.");

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

    {
         ::wxPropertyGridIteratorBase *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_wxPropertyGridIteratorBase, &sipCpp))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp->Prev();
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_PropertyGridIteratorBase, sipName_Prev, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxPropertyGridIteratorBase_SetBaseParent, "SetBaseParent(baseParent)\n"
"\n"
"Set base parent, ie a property when, in which iteration returns, it\n"
"ends.");

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

    {
         ::wxPGProperty* baseParent;
         ::wxPropertyGridIteratorBase *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ8", &sipSelf, sipType_wxPropertyGridIteratorBase, &sipCpp, sipType_wxPGProperty, &baseParent))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp->SetBaseParent(baseParent);
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_PropertyGridIteratorBase, sipName_SetBaseParent, SIP_NULLPTR);

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_wxPropertyGridIteratorBase(void *, int);}
static void release_wxPropertyGridIteratorBase(void *sipCppV, int)
{
    Py_BEGIN_ALLOW_THREADS

    delete reinterpret_cast< ::wxPropertyGridIteratorBase *>(sipCppV);

    Py_END_ALLOW_THREADS
}


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


extern "C" {static void *array_wxPropertyGridIteratorBase(SIP_SSIZE_T);}
static void *array_wxPropertyGridIteratorBase(SIP_SSIZE_T sipNrElem)
{
    return new  ::wxPropertyGridIteratorBase[sipNrElem];
}


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


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


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

    {
        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, ""))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp = new  ::wxPropertyGridIteratorBase();
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
            {
                delete sipCpp;
                return SIP_NULLPTR;
            }

            return sipCpp;
        }
    }

    {
        const  ::wxPropertyGridIteratorBase* a0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, "J9", sipType_wxPropertyGridIteratorBase, &a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new  ::wxPropertyGridIteratorBase(*a0);
            Py_END_ALLOW_THREADS

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


static PyMethodDef methods_wxPropertyGridIteratorBase[] = {
    {SIP_MLNAME_CAST(sipName_Assign), SIP_MLMETH_CAST(meth_wxPropertyGridIteratorBase_Assign), METH_VARARGS|METH_KEYWORDS, SIP_MLDOC_CAST(doc_wxPropertyGridIteratorBase_Assign)},
    {SIP_MLNAME_CAST(sipName_AtEnd), meth_wxPropertyGridIteratorBase_AtEnd, METH_VARARGS, SIP_MLDOC_CAST(doc_wxPropertyGridIteratorBase_AtEnd)},
    {SIP_MLNAME_CAST(sipName_GetProperty), meth_wxPropertyGridIteratorBase_GetProperty, METH_VARARGS, SIP_MLDOC_CAST(doc_wxPropertyGridIteratorBase_GetProperty)},
    {SIP_MLNAME_CAST(sipName_Init), SIP_MLMETH_CAST(meth_wxPropertyGridIteratorBase_Init), METH_VARARGS|METH_KEYWORDS, SIP_MLDOC_CAST(doc_wxPropertyGridIteratorBase_Init)},
    {SIP_MLNAME_CAST(sipName_Next), SIP_MLMETH_CAST(meth_wxPropertyGridIteratorBase_Next), METH_VARARGS|METH_KEYWORDS, SIP_MLDOC_CAST(doc_wxPropertyGridIteratorBase_Next)},
    {SIP_MLNAME_CAST(sipName_Prev), meth_wxPropertyGridIteratorBase_Prev, METH_VARARGS, SIP_MLDOC_CAST(doc_wxPropertyGridIteratorBase_Prev)},
    {SIP_MLNAME_CAST(sipName_SetBaseParent), SIP_MLMETH_CAST(meth_wxPropertyGridIteratorBase_SetBaseParent), METH_VARARGS|METH_KEYWORDS, SIP_MLDOC_CAST(doc_wxPropertyGridIteratorBase_SetBaseParent)}
};

sipVariableDef variables_wxPropertyGridIteratorBase[] = {
    {PropertyVariable, sipName_Property, &methods_wxPropertyGridIteratorBase[2], SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
};

PyDoc_STRVAR(doc_wxPropertyGridIteratorBase, "PropertyGridIteratorBase()");


sipClassTypeDef sipTypeDef__propgrid_wxPropertyGridIteratorBase = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_CLASS,
        sipNameNr_wxPropertyGridIteratorBase,
        {SIP_NULLPTR},
        SIP_NULLPTR
    },
    {
        sipNameNr_PropertyGridIteratorBase,
        {0, 0, 1},
        7, methods_wxPropertyGridIteratorBase,
        0, SIP_NULLPTR,
        1, variables_wxPropertyGridIteratorBase,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_wxPropertyGridIteratorBase,
    -1,
    -1,
    SIP_NULLPTR,
    SIP_NULLPTR,
    init_type_wxPropertyGridIteratorBase,
    SIP_NULLPTR,
    SIP_NULLPTR,
#if PY_MAJOR_VERSION >= 3
    SIP_NULLPTR,
    SIP_NULLPTR,
#else
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
#endif
    dealloc_wxPropertyGridIteratorBase,
    assign_wxPropertyGridIteratorBase,
    array_wxPropertyGridIteratorBase,
    copy_wxPropertyGridIteratorBase,
    release_wxPropertyGridIteratorBase,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR
};
