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

#include "sipAPI_dataview.h"
        #include <wx/dataview.h>
        #include <wx/dataview.h>
        #include <wx/bmpbndl.h>
        #include <wx/icon.h>
        #include <wx/dataview.h>
        #include <wx/dataview.h>


class sipwxDataViewTreeStore : public ::wxDataViewTreeStore
{
public:
    sipwxDataViewTreeStore();
    virtual ~sipwxDataViewTreeStore();

    /*
     * There is a protected method for every virtual method visible from
     * this class.
     */
protected:
    int Compare(const ::wxDataViewItem&, const ::wxDataViewItem&, uint, bool) const SIP_OVERRIDE;
    bool GetAttr(const ::wxDataViewItem&, uint, ::wxDataViewItemAttr&) const SIP_OVERRIDE;
    bool IsEnabled(const ::wxDataViewItem&, uint) const SIP_OVERRIDE;
    uint GetChildren(const ::wxDataViewItem&, ::wxDataViewItemArray&) const SIP_OVERRIDE;
    ::wxDataViewItem GetParent(const ::wxDataViewItem&) const SIP_OVERRIDE;
    void GetValue(::wxVariant&, const ::wxDataViewItem&, uint) const SIP_OVERRIDE;
    bool HasContainerColumns(const ::wxDataViewItem&) const SIP_OVERRIDE;
    bool HasDefaultCompare() const SIP_OVERRIDE;
    bool HasValue(const ::wxDataViewItem&, uint) const SIP_OVERRIDE;
    bool IsContainer(const ::wxDataViewItem&) const SIP_OVERRIDE;
    void Resort() SIP_OVERRIDE;
    bool SetValue(const ::wxDVCVariant&, const ::wxDataViewItem&, uint) SIP_OVERRIDE;
    bool IsListModel() const SIP_OVERRIDE;
    bool IsVirtualListModel() const SIP_OVERRIDE;

public:
    sipSimpleWrapper *sipPySelf;

private:
    sipwxDataViewTreeStore(const sipwxDataViewTreeStore &);
    sipwxDataViewTreeStore &operator = (const sipwxDataViewTreeStore &);

    char sipPyMethods[14];
};

sipwxDataViewTreeStore::sipwxDataViewTreeStore(): ::wxDataViewTreeStore(), sipPySelf(SIP_NULLPTR)
{
    memset(sipPyMethods, 0, sizeof (sipPyMethods));
}

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

int sipwxDataViewTreeStore::Compare(const ::wxDataViewItem& item1, const ::wxDataViewItem& item2, uint column, bool ascending) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[0]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_Compare);

    if (!sipMeth)
        return ::wxDataViewTreeStore::Compare(item1, item2, column, ascending);

    extern int sipVH__dataview_7(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const ::wxDataViewItem&, const ::wxDataViewItem&, uint, bool);

    return sipVH__dataview_7(sipGILState, 0, sipPySelf, sipMeth, item1, item2, column, ascending);
}

bool sipwxDataViewTreeStore::GetAttr(const ::wxDataViewItem& item, uint col, ::wxDataViewItemAttr& attr) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[1]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_GetAttr);

    if (!sipMeth)
        return ::wxDataViewTreeStore::GetAttr(item, col, attr);

    extern bool sipVH__dataview_8(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const ::wxDataViewItem&, uint, ::wxDataViewItemAttr&);

    return sipVH__dataview_8(sipGILState, 0, sipPySelf, sipMeth, item, col, attr);
}

bool sipwxDataViewTreeStore::IsEnabled(const ::wxDataViewItem& item, uint col) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[2]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_IsEnabled);

    if (!sipMeth)
        return ::wxDataViewTreeStore::IsEnabled(item, col);

    extern bool sipVH__dataview_6(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const ::wxDataViewItem&, uint);

    return sipVH__dataview_6(sipGILState, 0, sipPySelf, sipMeth, item, col);
}

uint sipwxDataViewTreeStore::GetChildren(const ::wxDataViewItem& item, ::wxDataViewItemArray& children) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[3]), const_cast<sipSimpleWrapper **>(&sipPySelf), sipName_DataViewTreeStore, sipName_GetChildren);

    if (!sipMeth)
        return 0;

    extern uint sipVH__dataview_9(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const ::wxDataViewItem&, ::wxDataViewItemArray&);

    return sipVH__dataview_9(sipGILState, 0, sipPySelf, sipMeth, item, children);
}

::wxDataViewItem sipwxDataViewTreeStore::GetParent(const ::wxDataViewItem& item) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[4]), const_cast<sipSimpleWrapper **>(&sipPySelf), sipName_DataViewTreeStore, sipName_GetParent);

    if (!sipMeth)
        return ::wxDataViewItem();

    extern ::wxDataViewItem sipVH__dataview_10(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const ::wxDataViewItem&);

    return sipVH__dataview_10(sipGILState, 0, sipPySelf, sipMeth, item);
}

void sipwxDataViewTreeStore::GetValue(::wxVariant& variant, const ::wxDataViewItem& item, uint col) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[5]), const_cast<sipSimpleWrapper **>(&sipPySelf), sipName_DataViewTreeStore, sipName_GetValue);

    if (!sipMeth)
        return;

    extern void sipVH__dataview_11(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, ::wxVariant&, const ::wxDataViewItem&, uint);

    sipVH__dataview_11(sipGILState, 0, sipPySelf, sipMeth, variant, item, col);
}

bool sipwxDataViewTreeStore::HasContainerColumns(const ::wxDataViewItem& item) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[6]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_HasContainerColumns);

    if (!sipMeth)
        return ::wxDataViewTreeStore::HasContainerColumns(item);

    extern bool sipVH__dataview_2(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const ::wxDataViewItem&);

    return sipVH__dataview_2(sipGILState, 0, sipPySelf, sipMeth, item);
}

bool sipwxDataViewTreeStore::HasDefaultCompare() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[7]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_HasDefaultCompare);

    if (!sipMeth)
        return ::wxDataViewTreeStore::HasDefaultCompare();

    extern bool sipVH__dataview_0(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH__dataview_0(sipGILState, 0, sipPySelf, sipMeth);
}

bool sipwxDataViewTreeStore::HasValue(const ::wxDataViewItem& item, uint col) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[8]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_HasValue);

    if (!sipMeth)
        return ::wxDataViewTreeStore::HasValue(item, col);

    extern bool sipVH__dataview_6(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const ::wxDataViewItem&, uint);

    return sipVH__dataview_6(sipGILState, 0, sipPySelf, sipMeth, item, col);
}

bool sipwxDataViewTreeStore::IsContainer(const ::wxDataViewItem& item) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[9]), const_cast<sipSimpleWrapper **>(&sipPySelf), sipName_DataViewTreeStore, sipName_IsContainer);

    if (!sipMeth)
        return 0;

    extern bool sipVH__dataview_2(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const ::wxDataViewItem&);

    return sipVH__dataview_2(sipGILState, 0, sipPySelf, sipMeth, item);
}

void sipwxDataViewTreeStore::Resort()
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[10], &sipPySelf, SIP_NULLPTR, sipName_Resort);

    if (!sipMeth)
    {
        ::wxDataViewTreeStore::Resort();
        return;
    }

    extern void sipVH__dataview_5(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    sipVH__dataview_5(sipGILState, 0, sipPySelf, sipMeth);
}

bool sipwxDataViewTreeStore::SetValue(const ::wxDVCVariant& variant, const ::wxDataViewItem& item, uint col)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[11], &sipPySelf, sipName_DataViewTreeStore, sipName_SetValue);

    if (!sipMeth)
        return 0;

    extern bool sipVH__dataview_12(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const ::wxDVCVariant&, const ::wxDataViewItem&, uint);

    return sipVH__dataview_12(sipGILState, 0, sipPySelf, sipMeth, variant, item, col);
}

bool sipwxDataViewTreeStore::IsListModel() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[12]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_IsListModel);

    if (!sipMeth)
        return ::wxDataViewTreeStore::IsListModel();

    extern bool sipVH__dataview_0(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH__dataview_0(sipGILState, 0, sipPySelf, sipMeth);
}

bool sipwxDataViewTreeStore::IsVirtualListModel() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[13]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_IsVirtualListModel);

    if (!sipMeth)
        return ::wxDataViewTreeStore::IsVirtualListModel();

    extern bool sipVH__dataview_0(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH__dataview_0(sipGILState, 0, sipPySelf, sipMeth);
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_AppendContainer, "AppendContainer(parent, text, icon=wx.BitmapBundle(), expanded=wx.BitmapBundle(), data=None) -> DataViewItem\n"
"\n"
"Append a container.");

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

    {
        const ::wxDataViewItem* parent;
        const ::wxString* text;
        int textState = 0;
        const ::wxBitmapBundle& icondef = wxBitmapBundle();
        const ::wxBitmapBundle* icon = &icondef;
        int iconState = 0;
        const ::wxBitmapBundle& expandeddef = wxBitmapBundle();
        const ::wxBitmapBundle* expanded = &expandeddef;
        int expandedState = 0;
        ::wxClientData* data = 0;
        int dataState = 0;
        ::wxDataViewTreeStore *sipCpp;

        static const char *sipKwdList[] = {
            sipName_parent,
            sipName_text,
            sipName_icon,
            sipName_expanded,
            sipName_data,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9J1|J1J1J2", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &parent, sipType_wxString, &text, &textState, sipType_wxBitmapBundle, &icon, &iconState, sipType_wxBitmapBundle, &expanded, &expandedState, sipType_wxClientData, &data, &dataState))
        {
            ::wxDataViewItem*sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = new ::wxDataViewItem(sipCpp->AppendContainer(*parent, *text, *icon, *expanded, data));
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast< ::wxString *>(text), sipType_wxString, textState);
            sipReleaseType(const_cast< ::wxBitmapBundle *>(icon), sipType_wxBitmapBundle, iconState);
            sipReleaseType(const_cast< ::wxBitmapBundle *>(expanded), sipType_wxBitmapBundle, expandedState);
            sipReleaseType(data, sipType_wxClientData, dataState);

            if (PyErr_Occurred())
                return 0;

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

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_AppendContainer, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_AppendItem, "AppendItem(parent, text, icon=wx.BitmapBundle(), data=None) -> DataViewItem\n"
"\n"
"Append an item.");

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

    {
        const ::wxDataViewItem* parent;
        const ::wxString* text;
        int textState = 0;
        const ::wxBitmapBundle& icondef = wxBitmapBundle();
        const ::wxBitmapBundle* icon = &icondef;
        int iconState = 0;
        ::wxClientData* data = 0;
        int dataState = 0;
        ::wxDataViewTreeStore *sipCpp;

        static const char *sipKwdList[] = {
            sipName_parent,
            sipName_text,
            sipName_icon,
            sipName_data,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9J1|J1J2", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &parent, sipType_wxString, &text, &textState, sipType_wxBitmapBundle, &icon, &iconState, sipType_wxClientData, &data, &dataState))
        {
            ::wxDataViewItem*sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = new ::wxDataViewItem(sipCpp->AppendItem(*parent, *text, *icon, data));
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast< ::wxString *>(text), sipType_wxString, textState);
            sipReleaseType(const_cast< ::wxBitmapBundle *>(icon), sipType_wxBitmapBundle, iconState);
            sipReleaseType(data, sipType_wxClientData, dataState);

            if (PyErr_Occurred())
                return 0;

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

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_AppendItem, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_DeleteAllItems, "DeleteAllItems() -> None\n"
"\n"
"Delete all item in the model.");

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

    {
        ::wxDataViewTreeStore *sipCpp;

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

            Py_BEGIN_ALLOW_THREADS
            sipCpp->DeleteAllItems();
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_DeleteAllItems, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_DeleteChildren, "DeleteChildren(item) -> None\n"
"\n"
"Delete all children of the item, but not the item itself.");

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

    {
        const ::wxDataViewItem* item;
        ::wxDataViewTreeStore *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &item))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp->DeleteChildren(*item);
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_DeleteChildren, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_DeleteItem, "DeleteItem(item) -> None\n"
"\n"
"Delete this item.");

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

    {
        const ::wxDataViewItem* item;
        ::wxDataViewTreeStore *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &item))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp->DeleteItem(*item);
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_DeleteItem, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_GetChildCount, "GetChildCount(parent) -> int\n"
"\n"
"Return the number of children of item.");

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

    {
        const ::wxDataViewItem* parent;
        const ::wxDataViewTreeStore *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &parent))
        {
            int sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->GetChildCount(*parent);
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

            return PyLong_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_GetChildCount, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_GetItemData, "GetItemData(item) -> ClientData\n"
"\n"
"Returns the client data associated with the item.");

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

    {
        const ::wxDataViewItem* item;
        const ::wxDataViewTreeStore *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &item))
        {
            ::wxClientData*sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->GetItemData(*item);
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

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

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_GetItemData, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_GetItemExpandedIcon, "GetItemExpandedIcon(item) -> wx.Icon\n"
"\n"
"Returns the icon to display in expanded containers.");

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

    {
        const ::wxDataViewItem* item;
        const ::wxDataViewTreeStore *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &item))
        {
            ::wxIcon*sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = new ::wxIcon(sipCpp->GetItemExpandedIcon(*item));
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

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

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_GetItemExpandedIcon, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_GetItemIcon, "GetItemIcon(item) -> wx.Icon\n"
"\n"
"Returns the icon of the item.");

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

    {
        const ::wxDataViewItem* item;
        const ::wxDataViewTreeStore *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &item))
        {
            ::wxIcon*sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = new ::wxIcon(sipCpp->GetItemIcon(*item));
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

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

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_GetItemIcon, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_GetItemText, "GetItemText(item) -> str\n"
"\n"
"Returns the text of the item.");

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

    {
        const ::wxDataViewItem* item;
        const ::wxDataViewTreeStore *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &item))
        {
            ::wxString*sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = new ::wxString(sipCpp->GetItemText(*item));
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

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

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_GetItemText, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_GetNthChild, "GetNthChild(parent, pos) -> DataViewItem\n"
"\n"
"Returns the nth child item of item.");

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

    {
        const ::wxDataViewItem* parent;
        uint pos;
        const ::wxDataViewTreeStore *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9u", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &parent, &pos))
        {
            ::wxDataViewItem*sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = new ::wxDataViewItem(sipCpp->GetNthChild(*parent, pos));
            Py_END_ALLOW_THREADS

            if (PyErr_Occurred())
                return 0;

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

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_GetNthChild, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_InsertContainer, "InsertContainer(parent, previous, text, icon=wx.BitmapBundle(), expanded=wx.BitmapBundle(), data=None) -> DataViewItem\n"
"\n"
"Inserts a container after previous.");

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

    {
        const ::wxDataViewItem* parent;
        const ::wxDataViewItem* previous;
        const ::wxString* text;
        int textState = 0;
        const ::wxBitmapBundle& icondef = wxBitmapBundle();
        const ::wxBitmapBundle* icon = &icondef;
        int iconState = 0;
        const ::wxBitmapBundle& expandeddef = wxBitmapBundle();
        const ::wxBitmapBundle* expanded = &expandeddef;
        int expandedState = 0;
        ::wxClientData* data = 0;
        int dataState = 0;
        ::wxDataViewTreeStore *sipCpp;

        static const char *sipKwdList[] = {
            sipName_parent,
            sipName_previous,
            sipName_text,
            sipName_icon,
            sipName_expanded,
            sipName_data,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9J9J1|J1J1J2", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &parent, sipType_wxDataViewItem, &previous, sipType_wxString, &text, &textState, sipType_wxBitmapBundle, &icon, &iconState, sipType_wxBitmapBundle, &expanded, &expandedState, sipType_wxClientData, &data, &dataState))
        {
            ::wxDataViewItem*sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = new ::wxDataViewItem(sipCpp->InsertContainer(*parent, *previous, *text, *icon, *expanded, data));
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast< ::wxString *>(text), sipType_wxString, textState);
            sipReleaseType(const_cast< ::wxBitmapBundle *>(icon), sipType_wxBitmapBundle, iconState);
            sipReleaseType(const_cast< ::wxBitmapBundle *>(expanded), sipType_wxBitmapBundle, expandedState);
            sipReleaseType(data, sipType_wxClientData, dataState);

            if (PyErr_Occurred())
                return 0;

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

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_InsertContainer, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_InsertItem, "InsertItem(parent, previous, text, icon=wx.BitmapBundle(), data=None) -> DataViewItem\n"
"\n"
"Inserts an item after previous.");

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

    {
        const ::wxDataViewItem* parent;
        const ::wxDataViewItem* previous;
        const ::wxString* text;
        int textState = 0;
        const ::wxBitmapBundle& icondef = wxBitmapBundle();
        const ::wxBitmapBundle* icon = &icondef;
        int iconState = 0;
        ::wxClientData* data = 0;
        int dataState = 0;
        ::wxDataViewTreeStore *sipCpp;

        static const char *sipKwdList[] = {
            sipName_parent,
            sipName_previous,
            sipName_text,
            sipName_icon,
            sipName_data,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9J9J1|J1J2", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &parent, sipType_wxDataViewItem, &previous, sipType_wxString, &text, &textState, sipType_wxBitmapBundle, &icon, &iconState, sipType_wxClientData, &data, &dataState))
        {
            ::wxDataViewItem*sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = new ::wxDataViewItem(sipCpp->InsertItem(*parent, *previous, *text, *icon, data));
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast< ::wxString *>(text), sipType_wxString, textState);
            sipReleaseType(const_cast< ::wxBitmapBundle *>(icon), sipType_wxBitmapBundle, iconState);
            sipReleaseType(data, sipType_wxClientData, dataState);

            if (PyErr_Occurred())
                return 0;

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

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_InsertItem, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_PrependContainer, "PrependContainer(parent, text, icon=wx.BitmapBundle(), expanded=wx.BitmapBundle(), data=None) -> DataViewItem\n"
"\n"
"Inserts a container before the first child item or parent.");

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

    {
        const ::wxDataViewItem* parent;
        const ::wxString* text;
        int textState = 0;
        const ::wxBitmapBundle& icondef = wxBitmapBundle();
        const ::wxBitmapBundle* icon = &icondef;
        int iconState = 0;
        const ::wxBitmapBundle& expandeddef = wxBitmapBundle();
        const ::wxBitmapBundle* expanded = &expandeddef;
        int expandedState = 0;
        ::wxClientData* data = 0;
        int dataState = 0;
        ::wxDataViewTreeStore *sipCpp;

        static const char *sipKwdList[] = {
            sipName_parent,
            sipName_text,
            sipName_icon,
            sipName_expanded,
            sipName_data,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9J1|J1J1J2", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &parent, sipType_wxString, &text, &textState, sipType_wxBitmapBundle, &icon, &iconState, sipType_wxBitmapBundle, &expanded, &expandedState, sipType_wxClientData, &data, &dataState))
        {
            ::wxDataViewItem*sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = new ::wxDataViewItem(sipCpp->PrependContainer(*parent, *text, *icon, *expanded, data));
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast< ::wxString *>(text), sipType_wxString, textState);
            sipReleaseType(const_cast< ::wxBitmapBundle *>(icon), sipType_wxBitmapBundle, iconState);
            sipReleaseType(const_cast< ::wxBitmapBundle *>(expanded), sipType_wxBitmapBundle, expandedState);
            sipReleaseType(data, sipType_wxClientData, dataState);

            if (PyErr_Occurred())
                return 0;

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

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_PrependContainer, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_PrependItem, "PrependItem(parent, text, icon=wx.BitmapBundle(), data=None) -> DataViewItem\n"
"\n"
"Inserts an item before the first child item or parent.");

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

    {
        const ::wxDataViewItem* parent;
        const ::wxString* text;
        int textState = 0;
        const ::wxBitmapBundle& icondef = wxBitmapBundle();
        const ::wxBitmapBundle* icon = &icondef;
        int iconState = 0;
        ::wxClientData* data = 0;
        int dataState = 0;
        ::wxDataViewTreeStore *sipCpp;

        static const char *sipKwdList[] = {
            sipName_parent,
            sipName_text,
            sipName_icon,
            sipName_data,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9J1|J1J2", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &parent, sipType_wxString, &text, &textState, sipType_wxBitmapBundle, &icon, &iconState, sipType_wxClientData, &data, &dataState))
        {
            ::wxDataViewItem*sipRes;

            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipRes = new ::wxDataViewItem(sipCpp->PrependItem(*parent, *text, *icon, data));
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast< ::wxString *>(text), sipType_wxString, textState);
            sipReleaseType(const_cast< ::wxBitmapBundle *>(icon), sipType_wxBitmapBundle, iconState);
            sipReleaseType(data, sipType_wxClientData, dataState);

            if (PyErr_Occurred())
                return 0;

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

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_PrependItem, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_SetItemData, "SetItemData(item, data) -> None\n"
"\n"
"Sets the client data associated with the item.");

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

    {
        const ::wxDataViewItem* item;
        ::wxClientData* data;
        int dataState = 0;
        ::wxDataViewTreeStore *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9J2", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &item, sipType_wxClientData, &data, &dataState))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp->SetItemData(*item, data);
            Py_END_ALLOW_THREADS
            sipReleaseType(data, sipType_wxClientData, dataState);

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_SetItemData, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_SetItemExpandedIcon, "SetItemExpandedIcon(item, icon) -> None\n"
"\n"
"Sets the expanded icon for the item.");

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

    {
        const ::wxDataViewItem* item;
        const ::wxBitmapBundle* icon;
        int iconState = 0;
        ::wxDataViewTreeStore *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9J1", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &item, sipType_wxBitmapBundle, &icon, &iconState))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp->SetItemExpandedIcon(*item, *icon);
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast< ::wxBitmapBundle *>(icon), sipType_wxBitmapBundle, iconState);

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_SetItemExpandedIcon, SIP_NULLPTR);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_wxDataViewTreeStore_SetItemIcon, "SetItemIcon(item, icon) -> None\n"
"\n"
"Sets the icon for the item.");

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

    {
        const ::wxDataViewItem* item;
        const ::wxBitmapBundle* icon;
        int iconState = 0;
        ::wxDataViewTreeStore *sipCpp;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "BJ9J1", &sipSelf, sipType_wxDataViewTreeStore, &sipCpp, sipType_wxDataViewItem, &item, sipType_wxBitmapBundle, &icon, &iconState))
        {
            PyErr_Clear();

            Py_BEGIN_ALLOW_THREADS
            sipCpp->SetItemIcon(*item, *icon);
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast< ::wxBitmapBundle *>(icon), sipType_wxBitmapBundle, iconState);

            if (PyErr_Occurred())
                return 0;

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_DataViewTreeStore, sipName_SetItemIcon, SIP_NULLPTR);

    return SIP_NULLPTR;
}


/* Cast a pointer to a type somewhere in its inheritance hierarchy. */
extern "C" {static void *cast_wxDataViewTreeStore(void *, const sipTypeDef *);}
static void *cast_wxDataViewTreeStore(void *sipCppV, const sipTypeDef *targetType)
{
    ::wxDataViewTreeStore *sipCpp = reinterpret_cast< ::wxDataViewTreeStore *>(sipCppV);

    if (targetType == sipType_wxDataViewTreeStore)
        return sipCppV;

    sipCppV = ((const sipClassTypeDef *)sipType_wxDataViewModel)->ctd_cast(static_cast< ::wxDataViewModel *>(sipCpp), targetType);
    if (sipCppV)
        return sipCppV;

    return SIP_NULLPTR;
}


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

    if (sipState & SIP_DERIVED_CLASS)
        delete reinterpret_cast<sipwxDataViewTreeStore *>(sipCppV);
    else
        delete reinterpret_cast< ::wxDataViewTreeStore *>(sipCppV);

    Py_END_ALLOW_THREADS
}


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

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


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

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

            Py_BEGIN_ALLOW_THREADS
            sipCpp = new sipwxDataViewTreeStore();
            Py_END_ALLOW_THREADS

            *sipOwner = Py_None;

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

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's super-types. */
static sipEncodedTypeDef supers_wxDataViewTreeStore[] = {{22, 255, 1}};


static PyMethodDef methods_wxDataViewTreeStore[] = {
    {sipName_AppendContainer, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_AppendContainer), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_AppendContainer},
    {sipName_AppendItem, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_AppendItem), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_AppendItem},
    {sipName_DeleteAllItems, meth_wxDataViewTreeStore_DeleteAllItems, METH_VARARGS, doc_wxDataViewTreeStore_DeleteAllItems},
    {sipName_DeleteChildren, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_DeleteChildren), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_DeleteChildren},
    {sipName_DeleteItem, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_DeleteItem), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_DeleteItem},
    {sipName_GetChildCount, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_GetChildCount), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_GetChildCount},
    {sipName_GetItemData, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_GetItemData), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_GetItemData},
    {sipName_GetItemExpandedIcon, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_GetItemExpandedIcon), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_GetItemExpandedIcon},
    {sipName_GetItemIcon, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_GetItemIcon), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_GetItemIcon},
    {sipName_GetItemText, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_GetItemText), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_GetItemText},
    {sipName_GetNthChild, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_GetNthChild), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_GetNthChild},
    {sipName_InsertContainer, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_InsertContainer), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_InsertContainer},
    {sipName_InsertItem, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_InsertItem), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_InsertItem},
    {sipName_PrependContainer, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_PrependContainer), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_PrependContainer},
    {sipName_PrependItem, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_PrependItem), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_PrependItem},
    {sipName_SetItemData, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_SetItemData), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_SetItemData},
    {sipName_SetItemExpandedIcon, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_SetItemExpandedIcon), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_SetItemExpandedIcon},
    {sipName_SetItemIcon, SIP_MLMETH_CAST(meth_wxDataViewTreeStore_SetItemIcon), METH_VARARGS|METH_KEYWORDS, doc_wxDataViewTreeStore_SetItemIcon}
};

PyDoc_STRVAR(doc_wxDataViewTreeStore, "DataViewTreeStore() -> None\n"
"\n"
"wxDataViewTreeStore is a specialised wxDataViewModel for storing\n"
"simple trees very much like wxTreeCtrl does and it offers a similar\n"
"API.");


sipClassTypeDef sipTypeDef__dataview_wxDataViewTreeStore = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_ABSTRACT|SIP_TYPE_CLASS,
        sipNameNr_wxDataViewTreeStore,
        SIP_NULLPTR,
        SIP_NULLPTR,
    },
    {
        sipNameNr_DataViewTreeStore,
        {0, 0, 1},
        18, methods_wxDataViewTreeStore,
        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_wxDataViewTreeStore,
    -1,
    -1,
    supers_wxDataViewTreeStore,
    SIP_NULLPTR,
    init_type_wxDataViewTreeStore,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_wxDataViewTreeStore,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    release_wxDataViewTreeStore,
    cast_wxDataViewTreeStore,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    sizeof (::wxDataViewTreeStore),
};
