/*
 * Module code.
 *
 * Generated by SIP 4.10.2 on Sun Jul 11 10:12:20 2010
 */

#include "sipAPIsolid.h"

#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.4.5/python/pykde4/sip/solid/device.sip"
#include <device.h>
#line 12 "sipsolidpart5.cpp"

#line 41 "/usr/local/share/py-sip/QtCore/qstring.sip"
#include <qstring.h>
#line 16 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qstringlist.sip"
#include <qstringlist.h>
#line 19 "sipsolidpart5.cpp"
#line 55 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.4.5/python/pykde4/sip/solid/deviceinterface.sip"
#include <deviceinterface.h>
#line 22 "sipsolidpart5.cpp"
#line 38 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 25 "sipsolidpart5.cpp"
#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.4.5/python/pykde4/sip/solid/predicate.sip"
#include <predicate.h>
#line 28 "sipsolidpart5.cpp"


extern "C" {static PyObject *meth_Solid_Device_allDevices(PyObject *, PyObject *);}
static PyObject *meth_Solid_Device_allDevices(PyObject *, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        if (sipParseArgs(&sipParseErr, sipArgs, ""))
        {
            QList<Solid::Device> *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QList<Solid::Device>(Solid::Device::allDevices());
            Py_END_ALLOW_THREADS

            return sipConvertFromNewType(sipRes,sipType_QList_0100Solid_Device,NULL);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_allDevices, NULL);

    return NULL;
}


extern "C" {static PyObject *meth_Solid_Device_listFromType(PyObject *, PyObject *);}
static PyObject *meth_Solid_Device_listFromType(PyObject *, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        Solid::DeviceInterface::Type a0;
        const QString& a1def = QString();
        const QString * a1 = &a1def;
        int a1State = 0;

        if (sipParseArgs(&sipParseErr, sipArgs, "E|J1", sipType_Solid_DeviceInterface_Type, &a0, sipType_QString,&a1, &a1State))
        {
            QList<Solid::Device> *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QList<Solid::Device>(Solid::Device::listFromType(a0,*a1));
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);

            return sipConvertFromNewType(sipRes,sipType_QList_0100Solid_Device,NULL);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_listFromType, NULL);

    return NULL;
}


extern "C" {static PyObject *meth_Solid_Device_listFromQuery(PyObject *, PyObject *);}
static PyObject *meth_Solid_Device_listFromQuery(PyObject *, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        const Solid::Predicate * a0;
        const QString& a1def = QString();
        const QString * a1 = &a1def;
        int a1State = 0;

        if (sipParseArgs(&sipParseErr, sipArgs, "J9|J1", sipType_Solid_Predicate, &a0, sipType_QString,&a1, &a1State))
        {
            QList<Solid::Device> *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QList<Solid::Device>(Solid::Device::listFromQuery(*a0,*a1));
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);

            return sipConvertFromNewType(sipRes,sipType_QList_0100Solid_Device,NULL);
        }
    }

    {
        const QString * a0;
        int a0State = 0;
        const QString& a1def = QString();
        const QString * a1 = &a1def;
        int a1State = 0;

        if (sipParseArgs(&sipParseErr, sipArgs, "J1|J1", sipType_QString,&a0, &a0State, sipType_QString,&a1, &a1State))
        {
            QList<Solid::Device> *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QList<Solid::Device>(Solid::Device::listFromQuery(*a0,*a1));
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);

            return sipConvertFromNewType(sipRes,sipType_QList_0100Solid_Device,NULL);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_listFromQuery, NULL);

    return NULL;
}


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

    {
        Solid::Device *sipCpp;

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

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->isValid();
            Py_END_ALLOW_THREADS

            return PyBool_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_isValid, NULL);

    return NULL;
}


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

    {
        Solid::Device *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Device, &sipCpp))
        {
            QString *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QString(sipCpp->udi());
            Py_END_ALLOW_THREADS

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

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_udi, NULL);

    return NULL;
}


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

    {
        Solid::Device *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Device, &sipCpp))
        {
            QString *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QString(sipCpp->parentUdi());
            Py_END_ALLOW_THREADS

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

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_parentUdi, NULL);

    return NULL;
}


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

    {
        Solid::Device *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Device, &sipCpp))
        {
            Solid::Device *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new Solid::Device(sipCpp->parent());
            Py_END_ALLOW_THREADS

            return sipConvertFromNewType(sipRes,sipType_Solid_Device,NULL);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_parent, NULL);

    return NULL;
}


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

    {
        Solid::Device *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Device, &sipCpp))
        {
            QString *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QString(sipCpp->vendor());
            Py_END_ALLOW_THREADS

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

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_vendor, NULL);

    return NULL;
}


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

    {
        Solid::Device *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Device, &sipCpp))
        {
            QString *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QString(sipCpp->product());
            Py_END_ALLOW_THREADS

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

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_product, NULL);

    return NULL;
}


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

    {
        Solid::Device *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Device, &sipCpp))
        {
            QString *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QString(sipCpp->icon());
            Py_END_ALLOW_THREADS

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

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_icon, NULL);

    return NULL;
}


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

    {
        Solid::DeviceInterface::Type a0;
        Solid::Device *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BE", &sipSelf, sipType_Solid_Device, &sipCpp, sipType_Solid_DeviceInterface_Type, &a0))
        {
            bool sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->isDeviceInterface(a0);
            Py_END_ALLOW_THREADS

            return PyBool_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_isDeviceInterface, NULL);

    return NULL;
}


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

    {
        Solid::DeviceInterface::Type a0;
        Solid::Device *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BE", &sipSelf, sipType_Solid_Device, &sipCpp, sipType_Solid_DeviceInterface_Type, &a0))
        {
            Solid::DeviceInterface *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->asDeviceInterface(a0);
            Py_END_ALLOW_THREADS

            return sipConvertFromType(sipRes,sipType_Solid_DeviceInterface,NULL);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_asDeviceInterface, NULL);

    return NULL;
}


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

    {
        Solid::Device *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Device, &sipCpp))
        {
            QStringList *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QStringList(sipCpp->emblems());
            Py_END_ALLOW_THREADS

            return sipConvertFromNewType(sipRes,sipType_QStringList,NULL);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_emblems, NULL);

    return NULL;
}


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

    {
        Solid::Device *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Device, &sipCpp))
        {
            QString *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QString(sipCpp->description());
            Py_END_ALLOW_THREADS

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

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Device, sipName_description, NULL);

    return NULL;
}


/* Cast a pointer to a type somewhere in its superclass hierarchy. */
extern "C" {static void *cast_Solid_Device(void *, const sipTypeDef *);}
static void *cast_Solid_Device(void *ptr, const sipTypeDef *targetType)
{
    if (targetType == sipType_Solid_Device)
        return ptr;

    return NULL;
}


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

    delete reinterpret_cast<Solid::Device *>(sipCppV);

    Py_END_ALLOW_THREADS
}


extern "C" {static void dealloc_Solid_Device(sipSimpleWrapper *);}
static void dealloc_Solid_Device(sipSimpleWrapper *sipSelf)
{
    if (sipIsPyOwned(sipSelf))
    {
        release_Solid_Device(sipSelf->u.cppPtr,0);
    }
}


extern "C" {static void *init_Solid_Device(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_Solid_Device(sipSimpleWrapper *, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **, PyObject **sipParseErr)
{
    Solid::Device *sipCpp = 0;

    {
        const QString& a0def = QString();
        const QString * a0 = &a0def;
        int a0State = 0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "|J1", sipType_QString,&a0, &a0State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new Solid::Device(*a0);
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);

            return sipCpp;
        }
    }

    {
        const Solid::Device * a0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "J9", sipType_Solid_Device, &a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new Solid::Device(*a0);
            Py_END_ALLOW_THREADS

            return sipCpp;
        }
    }

    return NULL;
}


static PyMethodDef methods_Solid_Device[] = {
    {SIP_MLNAME_CAST(sipName_allDevices), meth_Solid_Device_allDevices, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_asDeviceInterface), meth_Solid_Device_asDeviceInterface, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_description), meth_Solid_Device_description, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_emblems), meth_Solid_Device_emblems, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_icon), meth_Solid_Device_icon, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_isDeviceInterface), meth_Solid_Device_isDeviceInterface, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_isValid), meth_Solid_Device_isValid, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_listFromQuery), meth_Solid_Device_listFromQuery, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_listFromType), meth_Solid_Device_listFromType, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_parent), meth_Solid_Device_parent, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_parentUdi), meth_Solid_Device_parentUdi, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_product), meth_Solid_Device_product, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_udi), meth_Solid_Device_udi, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_vendor), meth_Solid_Device_vendor, METH_VARARGS, NULL}
};


pyqt4ClassTypeDef sipTypeDef_solid_Solid_Device = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_CLASS,
        sipNameNr_Solid__Device,
        {0}
    },
    {
        sipNameNr_Device,
        {3, 255, 0},
        14, methods_Solid_Device,
        0, 0,
        0, 0,
        {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    },
    0,
    sipNameNr_PyQt4_QtCore_pyqtWrapperType,
    -1,
    0,
    0,
    init_Solid_Device,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_Solid_Device,
    0,
    0,
    0,
    release_Solid_Device,
    cast_Solid_Device,
    0,
    0,
    0
},
    0,
    0,
    0
};

#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.4.5/python/pykde4/sip/solid/camera.sip"
#include <camera.h>
#line 579 "sipsolidpart5.cpp"

#line 40 "/usr/local/share/py-sip/QtCore/qobject.sip"
#include <qobject.h>
#line 583 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 586 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qstring.sip"
#include <qstring.h>
#line 589 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qstringlist.sip"
#include <qstringlist.h>
#line 592 "sipsolidpart5.cpp"
#line 55 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.4.5/python/pykde4/sip/solid/deviceinterface.sip"
#include <deviceinterface.h>
#line 595 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 598 "sipsolidpart5.cpp"
#line 318 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 601 "sipsolidpart5.cpp"
#line 305 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 604 "sipsolidpart5.cpp"
#line 38 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 607 "sipsolidpart5.cpp"
#line 43 "/usr/local/share/py-sip/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 610 "sipsolidpart5.cpp"
#line 40 "/usr/local/share/py-sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 613 "sipsolidpart5.cpp"
#line 125 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 616 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qthread.sip"
#include <qthread.h>
#line 619 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qregexp.sip"
#include <qregexp.h>
#line 622 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 625 "sipsolidpart5.cpp"


extern "C" {static PyObject *meth_Solid_Camera_deviceInterfaceType(PyObject *, PyObject *);}
static PyObject *meth_Solid_Camera_deviceInterfaceType(PyObject *, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        if (sipParseArgs(&sipParseErr, sipArgs, ""))
        {
            Solid::DeviceInterface::Type sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = Solid::Camera::deviceInterfaceType();
            Py_END_ALLOW_THREADS

            return sipConvertFromEnum(sipRes,sipType_Solid_DeviceInterface_Type);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Camera, sipName_deviceInterfaceType, NULL);

    return NULL;
}


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

    {
        Solid::Camera *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Camera, &sipCpp))
        {
            QStringList *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QStringList(sipCpp->supportedProtocols());
            Py_END_ALLOW_THREADS

            return sipConvertFromNewType(sipRes,sipType_QStringList,NULL);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Camera, sipName_supportedProtocols, NULL);

    return NULL;
}


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

    {
        QString a0def = QString();
        QString * a0 = &a0def;
        int a0State = 0;
        Solid::Camera *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B|J1", &sipSelf, sipType_Solid_Camera, &sipCpp, sipType_QString,&a0, &a0State))
        {
            QStringList *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QStringList(sipCpp->supportedDrivers(*a0));
            Py_END_ALLOW_THREADS
            sipReleaseType(a0,sipType_QString,a0State);

            return sipConvertFromNewType(sipRes,sipType_QStringList,NULL);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Camera, sipName_supportedDrivers, NULL);

    return NULL;
}


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

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

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_Solid_Camera, &sipCpp, sipType_QString,&a0, &a0State))
        {
            QVariant *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QVariant(sipCpp->driverHandle(*a0));
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);

            return sipConvertFromNewType(sipRes,sipType_QVariant,NULL);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Camera, sipName_driverHandle, NULL);

    return NULL;
}


/* Cast a pointer to a type somewhere in its superclass hierarchy. */
extern "C" {static void *cast_Solid_Camera(void *, const sipTypeDef *);}
static void *cast_Solid_Camera(void *ptr, const sipTypeDef *targetType)
{
    void *res;

    if (targetType == sipType_Solid_Camera)
        return ptr;

    if ((res = ((const sipClassTypeDef *)sipType_Solid_DeviceInterface)->ctd_cast((Solid::DeviceInterface *)(Solid::Camera *)ptr,targetType)) != NULL)
        return res;

    return NULL;
}


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

    delete reinterpret_cast<Solid::Camera *>(sipCppV);

    Py_END_ALLOW_THREADS
}


extern "C" {static void dealloc_Solid_Camera(sipSimpleWrapper *);}
static void dealloc_Solid_Camera(sipSimpleWrapper *sipSelf)
{
    if (sipIsPyOwned(sipSelf))
    {
        release_Solid_Camera(sipSelf->u.cppPtr,0);
    }
}


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


static PyMethodDef methods_Solid_Camera[] = {
    {SIP_MLNAME_CAST(sipName_deviceInterfaceType), meth_Solid_Camera_deviceInterfaceType, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_driverHandle), meth_Solid_Camera_driverHandle, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_supportedDrivers), meth_Solid_Camera_supportedDrivers, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_supportedProtocols), meth_Solid_Camera_supportedProtocols, METH_VARARGS, NULL}
};


pyqt4ClassTypeDef sipTypeDef_solid_Solid_Camera = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_SCC|SIP_TYPE_CLASS,
        sipNameNr_Solid__Camera,
        {0}
    },
    {
        sipNameNr_Camera,
        {3, 255, 0},
        4, methods_Solid_Camera,
        0, 0,
        0, 0,
        {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    },
    0,
    -1,
    -1,
    supers_Solid_Camera,
    0,
    0,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_Solid_Camera,
    0,
    0,
    0,
    release_Solid_Camera,
    cast_Solid_Camera,
    0,
    0,
    0
},
    &Solid::Camera::staticMetaObject,
    0,
    0
};

#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.4.5/python/pykde4/sip/solid/button.sip"
#include <button.h>
#line 843 "sipsolidpart5.cpp"

#line 40 "/usr/local/share/py-sip/QtCore/qobject.sip"
#include <qobject.h>
#line 847 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qstring.sip"
#include <qstring.h>
#line 850 "sipsolidpart5.cpp"
#line 55 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.4.5/python/pykde4/sip/solid/deviceinterface.sip"
#include <deviceinterface.h>
#line 853 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 856 "sipsolidpart5.cpp"
#line 318 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 859 "sipsolidpart5.cpp"
#line 305 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 862 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 865 "sipsolidpart5.cpp"
#line 38 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 868 "sipsolidpart5.cpp"
#line 43 "/usr/local/share/py-sip/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 871 "sipsolidpart5.cpp"
#line 40 "/usr/local/share/py-sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 874 "sipsolidpart5.cpp"
#line 125 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 877 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qthread.sip"
#include <qthread.h>
#line 880 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qregexp.sip"
#include <qregexp.h>
#line 883 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 886 "sipsolidpart5.cpp"


extern "C" {static PyObject *meth_Solid_Button_deviceInterfaceType(PyObject *, PyObject *);}
static PyObject *meth_Solid_Button_deviceInterfaceType(PyObject *, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        if (sipParseArgs(&sipParseErr, sipArgs, ""))
        {
            Solid::DeviceInterface::Type sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = Solid::Button::deviceInterfaceType();
            Py_END_ALLOW_THREADS

            return sipConvertFromEnum(sipRes,sipType_Solid_DeviceInterface_Type);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Button, sipName_deviceInterfaceType, NULL);

    return NULL;
}


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

    {
        Solid::Button *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Button, &sipCpp))
        {
            Solid::Button::ButtonType sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->type();
            Py_END_ALLOW_THREADS

            return sipConvertFromEnum(sipRes,sipType_Solid_Button_ButtonType);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Button, sipName_type, NULL);

    return NULL;
}


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

    {
        Solid::Button *sipCpp;

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

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->hasState();
            Py_END_ALLOW_THREADS

            return PyBool_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Button, sipName_hasState, NULL);

    return NULL;
}


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

    {
        Solid::Button *sipCpp;

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

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->stateValue();
            Py_END_ALLOW_THREADS

            return PyBool_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Button, sipName_stateValue, NULL);

    return NULL;
}


/* Cast a pointer to a type somewhere in its superclass hierarchy. */
extern "C" {static void *cast_Solid_Button(void *, const sipTypeDef *);}
static void *cast_Solid_Button(void *ptr, const sipTypeDef *targetType)
{
    void *res;

    if (targetType == sipType_Solid_Button)
        return ptr;

    if ((res = ((const sipClassTypeDef *)sipType_Solid_DeviceInterface)->ctd_cast((Solid::DeviceInterface *)(Solid::Button *)ptr,targetType)) != NULL)
        return res;

    return NULL;
}


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

    delete reinterpret_cast<Solid::Button *>(sipCppV);

    Py_END_ALLOW_THREADS
}


extern "C" {static void dealloc_Solid_Button(sipSimpleWrapper *);}
static void dealloc_Solid_Button(sipSimpleWrapper *sipSelf)
{
    if (sipIsPyOwned(sipSelf))
    {
        release_Solid_Button(sipSelf->u.cppPtr,0);
    }
}


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


static PyMethodDef methods_Solid_Button[] = {
    {SIP_MLNAME_CAST(sipName_deviceInterfaceType), meth_Solid_Button_deviceInterfaceType, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_hasState), meth_Solid_Button_hasState, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_stateValue), meth_Solid_Button_stateValue, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_type), meth_Solid_Button_type, METH_VARARGS, NULL}
};

static sipEnumMemberDef enummembers_Solid_Button[] = {
    {sipName_LidButton, Solid::Button::LidButton, 15},
    {sipName_PowerButton, Solid::Button::PowerButton, 15},
    {sipName_SleepButton, Solid::Button::SleepButton, 15},
    {sipName_TabletButton, Solid::Button::TabletButton, 15},
    {sipName_UnknownButtonType, Solid::Button::UnknownButtonType, 15},
};


/* Define this type's PyQt4 signals. */
static const pyqt4QtSignal pyqt4_signals_Solid_Button[] = {
    {"pressed(Solid::Button::ButtonType,const QString&)", 0, 0},
    {0, 0, 0}
};


pyqt4ClassTypeDef sipTypeDef_solid_Solid_Button = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_SCC|SIP_TYPE_CLASS,
        sipNameNr_Solid__Button,
        {0}
    },
    {
        sipNameNr_Button,
        {3, 255, 0},
        4, methods_Solid_Button,
        5, enummembers_Solid_Button,
        0, 0,
        {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    },
    0,
    -1,
    -1,
    supers_Solid_Button,
    0,
    0,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_Solid_Button,
    0,
    0,
    0,
    release_Solid_Button,
    cast_Solid_Button,
    0,
    0,
    0
},
    &Solid::Button::staticMetaObject,
    0,
    pyqt4_signals_Solid_Button
};

#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.4.5/python/pykde4/sip/solid/block.sip"
#include <block.h>
#line 1112 "sipsolidpart5.cpp"

#line 40 "/usr/local/share/py-sip/QtCore/qobject.sip"
#include <qobject.h>
#line 1116 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qstring.sip"
#include <qstring.h>
#line 1119 "sipsolidpart5.cpp"
#line 55 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.4.5/python/pykde4/sip/solid/deviceinterface.sip"
#include <deviceinterface.h>
#line 1122 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 1125 "sipsolidpart5.cpp"
#line 318 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 1128 "sipsolidpart5.cpp"
#line 305 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 1131 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 1134 "sipsolidpart5.cpp"
#line 38 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 1137 "sipsolidpart5.cpp"
#line 43 "/usr/local/share/py-sip/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 1140 "sipsolidpart5.cpp"
#line 40 "/usr/local/share/py-sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 1143 "sipsolidpart5.cpp"
#line 125 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 1146 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qthread.sip"
#include <qthread.h>
#line 1149 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qregexp.sip"
#include <qregexp.h>
#line 1152 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 1155 "sipsolidpart5.cpp"


extern "C" {static PyObject *meth_Solid_Block_deviceInterfaceType(PyObject *, PyObject *);}
static PyObject *meth_Solid_Block_deviceInterfaceType(PyObject *, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        if (sipParseArgs(&sipParseErr, sipArgs, ""))
        {
            Solid::DeviceInterface::Type sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = Solid::Block::deviceInterfaceType();
            Py_END_ALLOW_THREADS

            return sipConvertFromEnum(sipRes,sipType_Solid_DeviceInterface_Type);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Block, sipName_deviceInterfaceType, NULL);

    return NULL;
}


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

    {
        Solid::Block *sipCpp;

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

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->deviceMajor();
            Py_END_ALLOW_THREADS

            return SIPLong_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Block, sipName_deviceMajor, NULL);

    return NULL;
}


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

    {
        Solid::Block *sipCpp;

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

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->deviceMinor();
            Py_END_ALLOW_THREADS

            return SIPLong_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Block, sipName_deviceMinor, NULL);

    return NULL;
}


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

    {
        Solid::Block *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Block, &sipCpp))
        {
            QString *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QString(sipCpp->device());
            Py_END_ALLOW_THREADS

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

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Block, sipName_device, NULL);

    return NULL;
}


/* Cast a pointer to a type somewhere in its superclass hierarchy. */
extern "C" {static void *cast_Solid_Block(void *, const sipTypeDef *);}
static void *cast_Solid_Block(void *ptr, const sipTypeDef *targetType)
{
    void *res;

    if (targetType == sipType_Solid_Block)
        return ptr;

    if ((res = ((const sipClassTypeDef *)sipType_Solid_DeviceInterface)->ctd_cast((Solid::DeviceInterface *)(Solid::Block *)ptr,targetType)) != NULL)
        return res;

    return NULL;
}


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

    delete reinterpret_cast<Solid::Block *>(sipCppV);

    Py_END_ALLOW_THREADS
}


extern "C" {static void dealloc_Solid_Block(sipSimpleWrapper *);}
static void dealloc_Solid_Block(sipSimpleWrapper *sipSelf)
{
    if (sipIsPyOwned(sipSelf))
    {
        release_Solid_Block(sipSelf->u.cppPtr,0);
    }
}


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


static PyMethodDef methods_Solid_Block[] = {
    {SIP_MLNAME_CAST(sipName_device), meth_Solid_Block_device, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_deviceInterfaceType), meth_Solid_Block_deviceInterfaceType, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_deviceMajor), meth_Solid_Block_deviceMajor, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_deviceMinor), meth_Solid_Block_deviceMinor, METH_VARARGS, NULL}
};


pyqt4ClassTypeDef sipTypeDef_solid_Solid_Block = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_SCC|SIP_TYPE_CLASS,
        sipNameNr_Solid__Block,
        {0}
    },
    {
        sipNameNr_Block,
        {3, 255, 0},
        4, methods_Solid_Block,
        0, 0,
        0, 0,
        {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    },
    0,
    -1,
    -1,
    supers_Solid_Block,
    0,
    0,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_Solid_Block,
    0,
    0,
    0,
    release_Solid_Block,
    cast_Solid_Block,
    0,
    0,
    0
},
    &Solid::Block::staticMetaObject,
    0,
    0
};

#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.4.5/python/pykde4/sip/solid/battery.sip"
#include <battery.h>
#line 1366 "sipsolidpart5.cpp"

#line 40 "/usr/local/share/py-sip/QtCore/qobject.sip"
#include <qobject.h>
#line 1370 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qstring.sip"
#include <qstring.h>
#line 1373 "sipsolidpart5.cpp"
#line 55 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.4.5/python/pykde4/sip/solid/deviceinterface.sip"
#include <deviceinterface.h>
#line 1376 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 1379 "sipsolidpart5.cpp"
#line 318 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 1382 "sipsolidpart5.cpp"
#line 305 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 1385 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 1388 "sipsolidpart5.cpp"
#line 38 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 1391 "sipsolidpart5.cpp"
#line 43 "/usr/local/share/py-sip/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 1394 "sipsolidpart5.cpp"
#line 40 "/usr/local/share/py-sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 1397 "sipsolidpart5.cpp"
#line 125 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 1400 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qthread.sip"
#include <qthread.h>
#line 1403 "sipsolidpart5.cpp"
#line 41 "/usr/local/share/py-sip/QtCore/qregexp.sip"
#include <qregexp.h>
#line 1406 "sipsolidpart5.cpp"
#line 37 "/usr/local/share/py-sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 1409 "sipsolidpart5.cpp"


extern "C" {static PyObject *meth_Solid_Battery_deviceInterfaceType(PyObject *, PyObject *);}
static PyObject *meth_Solid_Battery_deviceInterfaceType(PyObject *, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        if (sipParseArgs(&sipParseErr, sipArgs, ""))
        {
            Solid::DeviceInterface::Type sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = Solid::Battery::deviceInterfaceType();
            Py_END_ALLOW_THREADS

            return sipConvertFromEnum(sipRes,sipType_Solid_DeviceInterface_Type);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Battery, sipName_deviceInterfaceType, NULL);

    return NULL;
}


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

    {
        Solid::Battery *sipCpp;

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

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->isPlugged();
            Py_END_ALLOW_THREADS

            return PyBool_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Battery, sipName_isPlugged, NULL);

    return NULL;
}


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

    {
        Solid::Battery *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Battery, &sipCpp))
        {
            Solid::Battery::BatteryType sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->type();
            Py_END_ALLOW_THREADS

            return sipConvertFromEnum(sipRes,sipType_Solid_Battery_BatteryType);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Battery, sipName_type, NULL);

    return NULL;
}


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

    {
        Solid::Battery *sipCpp;

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

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->chargePercent();
            Py_END_ALLOW_THREADS

            return SIPLong_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Battery, sipName_chargePercent, NULL);

    return NULL;
}


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

    {
        Solid::Battery *sipCpp;

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

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->isRechargeable();
            Py_END_ALLOW_THREADS

            return PyBool_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Battery, sipName_isRechargeable, NULL);

    return NULL;
}


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

    {
        Solid::Battery *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_Solid_Battery, &sipCpp))
        {
            Solid::Battery::ChargeState sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->chargeState();
            Py_END_ALLOW_THREADS

            return sipConvertFromEnum(sipRes,sipType_Solid_Battery_ChargeState);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_Battery, sipName_chargeState, NULL);

    return NULL;
}


/* Cast a pointer to a type somewhere in its superclass hierarchy. */
extern "C" {static void *cast_Solid_Battery(void *, const sipTypeDef *);}
static void *cast_Solid_Battery(void *ptr, const sipTypeDef *targetType)
{
    void *res;

    if (targetType == sipType_Solid_Battery)
        return ptr;

    if ((res = ((const sipClassTypeDef *)sipType_Solid_DeviceInterface)->ctd_cast((Solid::DeviceInterface *)(Solid::Battery *)ptr,targetType)) != NULL)
        return res;

    return NULL;
}


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

    delete reinterpret_cast<Solid::Battery *>(sipCppV);

    Py_END_ALLOW_THREADS
}


extern "C" {static void dealloc_Solid_Battery(sipSimpleWrapper *);}
static void dealloc_Solid_Battery(sipSimpleWrapper *sipSelf)
{
    if (sipIsPyOwned(sipSelf))
    {
        release_Solid_Battery(sipSelf->u.cppPtr,0);
    }
}


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


static PyMethodDef methods_Solid_Battery[] = {
    {SIP_MLNAME_CAST(sipName_chargePercent), meth_Solid_Battery_chargePercent, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_chargeState), meth_Solid_Battery_chargeState, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_deviceInterfaceType), meth_Solid_Battery_deviceInterfaceType, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_isPlugged), meth_Solid_Battery_isPlugged, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_isRechargeable), meth_Solid_Battery_isRechargeable, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_type), meth_Solid_Battery_type, METH_VARARGS, NULL}
};

static sipEnumMemberDef enummembers_Solid_Battery[] = {
    {sipName_CameraBattery, Solid::Battery::CameraBattery, 11},
    {sipName_Charging, Solid::Battery::Charging, 12},
    {sipName_Discharging, Solid::Battery::Discharging, 12},
    {sipName_KeyboardBattery, Solid::Battery::KeyboardBattery, 11},
    {sipName_KeyboardMouseBattery, Solid::Battery::KeyboardMouseBattery, 11},
    {sipName_MouseBattery, Solid::Battery::MouseBattery, 11},
    {sipName_NoCharge, Solid::Battery::NoCharge, 12},
    {sipName_PdaBattery, Solid::Battery::PdaBattery, 11},
    {sipName_PrimaryBattery, Solid::Battery::PrimaryBattery, 11},
    {sipName_UnknownBattery, Solid::Battery::UnknownBattery, 11},
    {sipName_UpsBattery, Solid::Battery::UpsBattery, 11},
};


/* Define this type's PyQt4 signals. */
static const pyqt4QtSignal pyqt4_signals_Solid_Battery[] = {
    {"plugStateChanged(bool,const QString&)", 0, 0},
    {"chargeStateChanged(int,const QString&)", 0, 0},
    {"chargePercentChanged(int,const QString&)", 0, 0},
    {0, 0, 0}
};


pyqt4ClassTypeDef sipTypeDef_solid_Solid_Battery = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_SCC|SIP_TYPE_CLASS,
        sipNameNr_Solid__Battery,
        {0}
    },
    {
        sipNameNr_Battery,
        {3, 255, 0},
        6, methods_Solid_Battery,
        11, enummembers_Solid_Battery,
        0, 0,
        {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    },
    0,
    -1,
    -1,
    supers_Solid_Battery,
    0,
    0,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_Solid_Battery,
    0,
    0,
    0,
    release_Solid_Battery,
    cast_Solid_Battery,
    0,
    0,
    0
},
    &Solid::Battery::staticMetaObject,
    0,
    pyqt4_signals_Solid_Battery
};
