/*
 * Module code.
 *
 * Generated by SIP 4.8.2 on Sun Oct 11 20:28:59 2009
 */

#include "sipAPIsolid.h"

#line 27 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/serialinterface.sip"
#include <solid/serialinterface.h>
#line 12 "sipsolidpart1.cpp"

#line 45 "/usr/local/share/py-sip/QtCore/qobject.sip"
#include <qobject.h>
#line 16 "sipsolidpart1.cpp"
#line 46 "/usr/local/share/py-sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 19 "sipsolidpart1.cpp"
#line 54 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/deviceinterface.sip"
#include <deviceinterface.h>
#line 22 "sipsolidpart1.cpp"
#line 46 "/usr/local/share/py-sip/QtCore/qstring.sip"
#include <qstring.h>
#line 25 "sipsolidpart1.cpp"
#line 42 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 28 "sipsolidpart1.cpp"
#line 297 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 31 "sipsolidpart1.cpp"
#line 284 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 34 "sipsolidpart1.cpp"
#line 328 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#include <qpair.h>
#line 424 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#include <qpair.h>
#line 637 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 699 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 721 "/usr/local/share/py-sip/QtCore/qlocale.sip"
#include <qlocale.h>
#line 43 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 43 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 130 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 43 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 43 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 43 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 210 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#include <qpair.h>
#line 210 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#include <qpair.h>
#line 65 "sipsolidpart1.cpp"
#line 42 "/usr/local/share/py-sip/QtCore/qfileinfo.sip"
#include <qfileinfo.h>
#line 68 "sipsolidpart1.cpp"
#line 42 "/usr/local/share/py-sip/QtCore/qabstractitemmodel.sip"
#include <qabstractitemmodel.h>
#line 71 "sipsolidpart1.cpp"
#line 48 "/usr/local/share/py-sip/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 74 "sipsolidpart1.cpp"
#line 46 "/usr/local/share/py-sip/QtCore/qurl.sip"
#include <qurl.h>
#line 77 "sipsolidpart1.cpp"
#line 46 "/usr/local/share/py-sip/QtCore/qlocale.sip"
#include <qlocale.h>
#line 80 "sipsolidpart1.cpp"
#line 45 "/usr/local/share/py-sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 83 "sipsolidpart1.cpp"
#line 42 "/usr/local/share/py-sip/QtCore/qthread.sip"
#include <qthread.h>
#line 86 "sipsolidpart1.cpp"
#line 46 "/usr/local/share/py-sip/QtCore/qregexp.sip"
#include <qregexp.h>
#line 89 "sipsolidpart1.cpp"
#line 42 "/usr/local/share/py-sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 92 "sipsolidpart1.cpp"


extern "C" {static PyObject *meth_Solid_SerialInterface_deviceInterfaceType(PyObject *, PyObject *);}
static PyObject *meth_Solid_SerialInterface_deviceInterfaceType(PyObject *,PyObject *sipArgs)
{
    int sipArgsParsed = 0;

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

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

            return sipConvertFromEnum(sipRes,sipType_Solid_DeviceInterface_Type);
        }
    }

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

    return NULL;
}


extern "C" {static PyObject *meth_Solid_SerialInterface_driverHandle(PyObject *, PyObject *);}
static PyObject *meth_Solid_SerialInterface_driverHandle(PyObject *sipSelf,PyObject *sipArgs)
{
    int sipArgsParsed = 0;
    bool sipSelfWasArg = (!sipSelf || sipIsDerived((sipSimpleWrapper *)sipSelf));

    {
        Solid::SerialInterface *sipCpp;

        if (sipParseArgs(&sipArgsParsed,sipArgs,"B",&sipSelf,sipType_Solid_SerialInterface,&sipCpp))
        {
            QVariant *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QVariant((sipSelfWasArg ? sipCpp->Solid::SerialInterface::driverHandle() : sipCpp->driverHandle()));
            Py_END_ALLOW_THREADS

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

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

    return NULL;
}


extern "C" {static PyObject *meth_Solid_SerialInterface_serialType(PyObject *, PyObject *);}
static PyObject *meth_Solid_SerialInterface_serialType(PyObject *sipSelf,PyObject *sipArgs)
{
    int sipArgsParsed = 0;
    bool sipSelfWasArg = (!sipSelf || sipIsDerived((sipSimpleWrapper *)sipSelf));

    {
        Solid::SerialInterface *sipCpp;

        if (sipParseArgs(&sipArgsParsed,sipArgs,"B",&sipSelf,sipType_Solid_SerialInterface,&sipCpp))
        {
            Solid::SerialInterface::SerialType sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = (sipSelfWasArg ? sipCpp->Solid::SerialInterface::serialType() : sipCpp->serialType());
            Py_END_ALLOW_THREADS

            return sipConvertFromEnum(sipRes,sipType_Solid_SerialInterface_SerialType);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipArgsParsed,sipName_SerialInterface,sipName_serialType);

    return NULL;
}


extern "C" {static PyObject *meth_Solid_SerialInterface_port(PyObject *, PyObject *);}
static PyObject *meth_Solid_SerialInterface_port(PyObject *sipSelf,PyObject *sipArgs)
{
    int sipArgsParsed = 0;
    bool sipSelfWasArg = (!sipSelf || sipIsDerived((sipSimpleWrapper *)sipSelf));

    {
        Solid::SerialInterface *sipCpp;

        if (sipParseArgs(&sipArgsParsed,sipArgs,"B",&sipSelf,sipType_Solid_SerialInterface,&sipCpp))
        {
            int sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = (sipSelfWasArg ? sipCpp->Solid::SerialInterface::port() : sipCpp->port());
            Py_END_ALLOW_THREADS

            return SIPLong_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipArgsParsed,sipName_SerialInterface,sipName_port);

    return NULL;
}


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

    if (targetType == sipType_Solid_SerialInterface)
        return ptr;

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

    return NULL;
}


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

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

    Py_END_ALLOW_THREADS
}


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


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


static PyMethodDef methods_Solid_SerialInterface[] = {
    {SIP_MLNAME_CAST(sipName_deviceInterfaceType), meth_Solid_SerialInterface_deviceInterfaceType, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_driverHandle), meth_Solid_SerialInterface_driverHandle, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_port), meth_Solid_SerialInterface_port, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_serialType), meth_Solid_SerialInterface_serialType, METH_VARARGS, NULL}
};

static sipEnumMemberDef enummembers_Solid_SerialInterface[] = {
    {sipName_Platform, Solid::SerialInterface::Platform, 46},
    {sipName_Unknown, Solid::SerialInterface::Unknown, 46},
    {sipName_Usb, Solid::SerialInterface::Usb, 46},
};


pyqt4ClassTypeDef pyqt4Type_solid_Solid_SerialInterface = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_SCC|SIP_TYPE_CLASS,
        sipNameNr_Solid__SerialInterface,
        {0}
    },
    sipNameNr_SerialInterface,
    -1,
    -1,
    {3, 255, 0},
    supers_Solid_SerialInterface,
    0,
    4, methods_Solid_SerialInterface,
    3, enummembers_Solid_SerialInterface,
    0, 0,
    0,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_Solid_SerialInterface,
    release_Solid_SerialInterface,
    cast_Solid_SerialInterface,
    0,
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    0,
    0
},
    0,
    &Solid::SerialInterface::staticMetaObject,
    0,
    0
};

#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/processor.sip"
#include <processor.h>
#line 307 "sipsolidpart1.cpp"

#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/processor.sip"
#include <processor.h>
#line 311 "sipsolidpart1.cpp"


extern "C" {static int slot_Solid_Processor_InstructionSets___bool__(PyObject *sipSelf);}
static int slot_Solid_Processor_InstructionSets___bool__(PyObject *sipSelf)
{
    Solid::Processor::InstructionSets *sipCpp = reinterpret_cast<Solid::Processor::InstructionSets *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_Solid_Processor_InstructionSets));

    if (!sipCpp)
        return -1;


    {
        {
            int sipRes = 0;

#line 271 "/usr/local/share/py-sip/QtCore/qglobal.sip"
        sipRes = (sipCpp->operator int() != 0);
#line 329 "sipsolidpart1.cpp"

            return sipRes;
        }
    }
}


extern "C" {static PyObject *slot_Solid_Processor_InstructionSets___ne__(PyObject *sipSelf,PyObject *sipArg);}
static PyObject *slot_Solid_Processor_InstructionSets___ne__(PyObject *sipSelf,PyObject *sipArg)
{
    Solid::Processor::InstructionSets *sipCpp = reinterpret_cast<Solid::Processor::InstructionSets *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_Solid_Processor_InstructionSets));

    if (!sipCpp)
        return 0;

    int sipArgsParsed = 0;

    {
        const Solid::Processor::InstructionSets * a0;
        int a0State = 0;

        if (sipParseArgs(&sipArgsParsed,sipArg,"1J1",sipType_Solid_Processor_InstructionSets,&a0,&a0State))
        {
            bool sipRes = 0;

#line 266 "/usr/local/share/py-sip/QtCore/qglobal.sip"
        sipRes = (sipCpp->operator int() != a0->operator int());
#line 357 "sipsolidpart1.cpp"

            sipReleaseType(const_cast<Solid::Processor::InstructionSets *>(a0),sipType_Solid_Processor_InstructionSets,a0State);

            return PyBool_FromLong(sipRes);
        }
    }

    return sipPySlotExtend(&sipModuleAPI_solid,ne_slot,sipType_Solid_Processor_InstructionSets,sipSelf,sipArg);
}


extern "C" {static PyObject *slot_Solid_Processor_InstructionSets___eq__(PyObject *sipSelf,PyObject *sipArg);}
static PyObject *slot_Solid_Processor_InstructionSets___eq__(PyObject *sipSelf,PyObject *sipArg)
{
    Solid::Processor::InstructionSets *sipCpp = reinterpret_cast<Solid::Processor::InstructionSets *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_Solid_Processor_InstructionSets));

    if (!sipCpp)
        return 0;

    int sipArgsParsed = 0;

    {
        const Solid::Processor::InstructionSets * a0;
        int a0State = 0;

        if (sipParseArgs(&sipArgsParsed,sipArg,"1J1",sipType_Solid_Processor_InstructionSets,&a0,&a0State))
        {
            bool sipRes = 0;

#line 261 "/usr/local/share/py-sip/QtCore/qglobal.sip"
        sipRes = (sipCpp->operator int() == a0->operator int());
#line 389 "sipsolidpart1.cpp"

            sipReleaseType(const_cast<Solid::Processor::InstructionSets *>(a0),sipType_Solid_Processor_InstructionSets,a0State);

            return PyBool_FromLong(sipRes);
        }
    }

    return sipPySlotExtend(&sipModuleAPI_solid,eq_slot,sipType_Solid_Processor_InstructionSets,sipSelf,sipArg);
}


extern "C" {static PyObject *slot_Solid_Processor_InstructionSets___invert__(PyObject *sipSelf);}
static PyObject *slot_Solid_Processor_InstructionSets___invert__(PyObject *sipSelf)
{
    Solid::Processor::InstructionSets *sipCpp = reinterpret_cast<Solid::Processor::InstructionSets *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_Solid_Processor_InstructionSets));

    if (!sipCpp)
        return 0;


    {
        {
            Solid::Processor::InstructionSets *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new Solid::Processor::InstructionSets(~(*sipCpp));
            Py_END_ALLOW_THREADS

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


extern "C" {static PyObject *slot_Solid_Processor_InstructionSets___and__(PyObject *sipArg0,PyObject *sipArg1);}
static PyObject *slot_Solid_Processor_InstructionSets___and__(PyObject *sipArg0,PyObject *sipArg1)
{
    int sipArgsParsed = 0;

    {
        Solid::Processor::InstructionSets * a0;
        int a0State = 0;
        int a1;

        if (sipParsePair(&sipArgsParsed,sipArg0,sipArg1,"J1i",sipType_Solid_Processor_InstructionSets,&a0,&a0State,&a1))
        {
            Solid::Processor::InstructionSets *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new Solid::Processor::InstructionSets((*a0 & a1));
            Py_END_ALLOW_THREADS

            sipReleaseType(a0,sipType_Solid_Processor_InstructionSets,a0State);

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

    return sipPySlotExtend(&sipModuleAPI_solid,and_slot,NULL,sipArg0,sipArg1);
}


extern "C" {static PyObject *slot_Solid_Processor_InstructionSets___xor__(PyObject *sipArg0,PyObject *sipArg1);}
static PyObject *slot_Solid_Processor_InstructionSets___xor__(PyObject *sipArg0,PyObject *sipArg1)
{
    int sipArgsParsed = 0;

    {
        Solid::Processor::InstructionSets * a0;
        int a0State = 0;
        Solid::Processor::InstructionSets * a1;
        int a1State = 0;

        if (sipParsePair(&sipArgsParsed,sipArg0,sipArg1,"J1J1",sipType_Solid_Processor_InstructionSets,&a0,&a0State,sipType_Solid_Processor_InstructionSets,&a1,&a1State))
        {
            Solid::Processor::InstructionSets *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new Solid::Processor::InstructionSets((*a0 ^ *a1));
            Py_END_ALLOW_THREADS

            sipReleaseType(a0,sipType_Solid_Processor_InstructionSets,a0State);
            sipReleaseType(a1,sipType_Solid_Processor_InstructionSets,a1State);

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

    return sipPySlotExtend(&sipModuleAPI_solid,xor_slot,NULL,sipArg0,sipArg1);
}


extern "C" {static PyObject *slot_Solid_Processor_InstructionSets___or__(PyObject *sipArg0,PyObject *sipArg1);}
static PyObject *slot_Solid_Processor_InstructionSets___or__(PyObject *sipArg0,PyObject *sipArg1)
{
    int sipArgsParsed = 0;

    {
        Solid::Processor::InstructionSets * a0;
        int a0State = 0;
        Solid::Processor::InstructionSets * a1;
        int a1State = 0;

        if (sipParsePair(&sipArgsParsed,sipArg0,sipArg1,"J1J1",sipType_Solid_Processor_InstructionSets,&a0,&a0State,sipType_Solid_Processor_InstructionSets,&a1,&a1State))
        {
            Solid::Processor::InstructionSets *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new Solid::Processor::InstructionSets((*a0 | *a1));
            Py_END_ALLOW_THREADS

            sipReleaseType(a0,sipType_Solid_Processor_InstructionSets,a0State);
            sipReleaseType(a1,sipType_Solid_Processor_InstructionSets,a1State);

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

    return sipPySlotExtend(&sipModuleAPI_solid,or_slot,NULL,sipArg0,sipArg1);
}


extern "C" {static PyObject *slot_Solid_Processor_InstructionSets___int__(PyObject *sipSelf);}
static PyObject *slot_Solid_Processor_InstructionSets___int__(PyObject *sipSelf)
{
    Solid::Processor::InstructionSets *sipCpp = reinterpret_cast<Solid::Processor::InstructionSets *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_Solid_Processor_InstructionSets));

    if (!sipCpp)
        return 0;


    {
        {
            int sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = *sipCpp;
            Py_END_ALLOW_THREADS

            return SIPLong_FromLong(sipRes);
        }
    }
}


extern "C" {static PyObject *slot_Solid_Processor_InstructionSets___ixor__(PyObject *sipSelf,PyObject *sipArg);}
static PyObject *slot_Solid_Processor_InstructionSets___ixor__(PyObject *sipSelf,PyObject *sipArg)
{
    if (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_Solid_Processor_InstructionSets)))
    {
        Py_INCREF(Py_NotImplemented);
        return Py_NotImplemented;
    }

    Solid::Processor::InstructionSets *sipCpp = reinterpret_cast<Solid::Processor::InstructionSets *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_Solid_Processor_InstructionSets));

    if (!sipCpp)
        return 0;

    int sipArgsParsed = 0;

    {
        Solid::Processor::InstructionSets * a0;
        int a0State = 0;

        if (sipParseArgs(&sipArgsParsed,sipArg,"1J1",sipType_Solid_Processor_InstructionSets,&a0,&a0State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->Solid::Processor::InstructionSets::operator^=(*a0);
            Py_END_ALLOW_THREADS

            sipReleaseType(a0,sipType_Solid_Processor_InstructionSets,a0State);

            Py_INCREF(sipSelf);
            return sipSelf;
        }
    }

    PyErr_Clear();

    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
}


extern "C" {static PyObject *slot_Solid_Processor_InstructionSets___ior__(PyObject *sipSelf,PyObject *sipArg);}
static PyObject *slot_Solid_Processor_InstructionSets___ior__(PyObject *sipSelf,PyObject *sipArg)
{
    if (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_Solid_Processor_InstructionSets)))
    {
        Py_INCREF(Py_NotImplemented);
        return Py_NotImplemented;
    }

    Solid::Processor::InstructionSets *sipCpp = reinterpret_cast<Solid::Processor::InstructionSets *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_Solid_Processor_InstructionSets));

    if (!sipCpp)
        return 0;

    int sipArgsParsed = 0;

    {
        Solid::Processor::InstructionSets * a0;
        int a0State = 0;

        if (sipParseArgs(&sipArgsParsed,sipArg,"1J1",sipType_Solid_Processor_InstructionSets,&a0,&a0State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->Solid::Processor::InstructionSets::operator|=(*a0);
            Py_END_ALLOW_THREADS

            sipReleaseType(a0,sipType_Solid_Processor_InstructionSets,a0State);

            Py_INCREF(sipSelf);
            return sipSelf;
        }
    }

    PyErr_Clear();

    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
}


extern "C" {static PyObject *slot_Solid_Processor_InstructionSets___iand__(PyObject *sipSelf,PyObject *sipArg);}
static PyObject *slot_Solid_Processor_InstructionSets___iand__(PyObject *sipSelf,PyObject *sipArg)
{
    if (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_Solid_Processor_InstructionSets)))
    {
        Py_INCREF(Py_NotImplemented);
        return Py_NotImplemented;
    }

    Solid::Processor::InstructionSets *sipCpp = reinterpret_cast<Solid::Processor::InstructionSets *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_Solid_Processor_InstructionSets));

    if (!sipCpp)
        return 0;

    int sipArgsParsed = 0;

    {
        int a0;

        if (sipParseArgs(&sipArgsParsed,sipArg,"1i",&a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->Solid::Processor::InstructionSets::operator&=(a0);
            Py_END_ALLOW_THREADS

            Py_INCREF(sipSelf);
            return sipSelf;
        }
    }

    PyErr_Clear();

    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
}


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

    return NULL;
}


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

    delete reinterpret_cast<Solid::Processor::InstructionSets *>(sipCppV);

    Py_END_ALLOW_THREADS
}


extern "C" {static void assign_Solid_Processor_InstructionSets(void *, const void*);}
static void assign_Solid_Processor_InstructionSets(void *sipDst, const void *sipSrc)
{
    *reinterpret_cast<Solid::Processor::InstructionSets *>(sipDst) = *reinterpret_cast<const Solid::Processor::InstructionSets *>(sipSrc);
}


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


extern "C" {static void *init_Solid_Processor_InstructionSets(sipSimpleWrapper *, PyObject *, PyObject **, int *);}
static void *init_Solid_Processor_InstructionSets(sipSimpleWrapper *, PyObject *sipArgs, PyObject **, int *sipArgsParsed)
{
    Solid::Processor::InstructionSets *sipCpp = 0;

    if (!sipCpp)
    {
        const Solid::Processor::InstructionSets * a0;
        int a0State = 0;

        if (sipParseArgs(sipArgsParsed,sipArgs,"J1",sipType_Solid_Processor_InstructionSets,&a0,&a0State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new Solid::Processor::InstructionSets(*a0);
            Py_END_ALLOW_THREADS

            sipReleaseType(const_cast<Solid::Processor::InstructionSets *>(a0),sipType_Solid_Processor_InstructionSets,a0State);
        }
    }

    if (!sipCpp)
    {
        int a0;

        if (sipParseArgs(sipArgsParsed,sipArgs,"i",&a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new Solid::Processor::InstructionSets(a0);
            Py_END_ALLOW_THREADS
        }
    }

    if (!sipCpp)
    {
        if (sipParseArgs(sipArgsParsed,sipArgs,""))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new Solid::Processor::InstructionSets();
            Py_END_ALLOW_THREADS
        }
    }

    return sipCpp;
}


extern "C" {static int convertTo_Solid_Processor_InstructionSets(PyObject *, void **, int *, PyObject *);}
static int convertTo_Solid_Processor_InstructionSets(PyObject *sipPy,void **sipCppPtrV,int *sipIsErr,PyObject *sipTransferObj)
{
    Solid::Processor::InstructionSets **sipCppPtr = reinterpret_cast<Solid::Processor::InstructionSets **>(sipCppPtrV);

#line 276 "/usr/local/share/py-sip/QtCore/qglobal.sip"
// Allow an instance of the base enum whenever a Solid::Processor::InstructionSets is expected.

if (sipIsErr == NULL)
    return (PyObject_TypeCheck(sipPy, sipTypeAsPyTypeObject(sipType_Solid_Processor_InstructionSet)) ||
            sipCanConvertToType(sipPy, sipType_Solid_Processor_InstructionSets, SIP_NO_CONVERTORS));

if (PyObject_TypeCheck(sipPy, sipTypeAsPyTypeObject(sipType_Solid_Processor_InstructionSet)))
{
    *sipCppPtr = new Solid::Processor::InstructionSets(SIPLong_AsLong(sipPy));

    return sipGetState(sipTransferObj);
}

*sipCppPtr = reinterpret_cast<Solid::Processor::InstructionSets *>(sipConvertToType(sipPy, sipType_Solid_Processor_InstructionSets, sipTransferObj, SIP_NO_CONVERTORS, 0, sipIsErr));

return 0;
#line 760 "sipsolidpart1.cpp"
}


/* Define this type's Python slots. */
static sipPySlotDef slots_Solid_Processor_InstructionSets[] = {
    {(void *)slot_Solid_Processor_InstructionSets___bool__, bool_slot},
    {(void *)slot_Solid_Processor_InstructionSets___ne__, ne_slot},
    {(void *)slot_Solid_Processor_InstructionSets___eq__, eq_slot},
    {(void *)slot_Solid_Processor_InstructionSets___invert__, invert_slot},
    {(void *)slot_Solid_Processor_InstructionSets___and__, and_slot},
    {(void *)slot_Solid_Processor_InstructionSets___xor__, xor_slot},
    {(void *)slot_Solid_Processor_InstructionSets___or__, or_slot},
    {(void *)slot_Solid_Processor_InstructionSets___int__, int_slot},
    {(void *)slot_Solid_Processor_InstructionSets___ixor__, ixor_slot},
    {(void *)slot_Solid_Processor_InstructionSets___ior__, ior_slot},
    {(void *)slot_Solid_Processor_InstructionSets___iand__, iand_slot},
    {0, (sipPySlotType)0}
};


pyqt4ClassTypeDef pyqt4Type_solid_Solid_Processor_InstructionSets = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_CLASS,
        sipNameNr_Solid__Processor__InstructionSets,
        {0}
    },
    sipNameNr_InstructionSets,
    sipNameNr_PyQt4_QtCore_pyqtWrapperType,
    -1,
    {42, 255, 0},
    0,
    slots_Solid_Processor_InstructionSets,
    0, 0,
    0, 0,
    0, 0,
    init_Solid_Processor_InstructionSets,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_Solid_Processor_InstructionSets,
    release_Solid_Processor_InstructionSets,
    cast_Solid_Processor_InstructionSets,
    convertTo_Solid_Processor_InstructionSets,
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    0,
    0
},
    assign_Solid_Processor_InstructionSets,
    0,
    1,
    0
};

#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/processor.sip"
#include <processor.h>
#line 828 "sipsolidpart1.cpp"

#line 45 "/usr/local/share/py-sip/QtCore/qobject.sip"
#include <qobject.h>
#line 832 "sipsolidpart1.cpp"
#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/processor.sip"
#include <processor.h>
#line 835 "sipsolidpart1.cpp"
#line 54 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/deviceinterface.sip"
#include <deviceinterface.h>
#line 838 "sipsolidpart1.cpp"
#line 46 "/usr/local/share/py-sip/QtCore/qstring.sip"
#include <qstring.h>
#line 841 "sipsolidpart1.cpp"
#line 42 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 844 "sipsolidpart1.cpp"
#line 297 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 847 "sipsolidpart1.cpp"
#line 284 "/usr/local/share/py-sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 850 "sipsolidpart1.cpp"
#line 46 "/usr/local/share/py-sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 853 "sipsolidpart1.cpp"
#line 328 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#include <qpair.h>
#line 424 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#include <qpair.h>
#line 637 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 699 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 721 "/usr/local/share/py-sip/QtCore/qlocale.sip"
#include <qlocale.h>
#line 43 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 43 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 130 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 43 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 43 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 43 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#line 210 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#include <qpair.h>
#line 210 "/usr/local/share/py-sip/QtCore/qlist.sip"
#include <qlist.h>
#include <qpair.h>
#line 884 "sipsolidpart1.cpp"
#line 42 "/usr/local/share/py-sip/QtCore/qfileinfo.sip"
#include <qfileinfo.h>
#line 887 "sipsolidpart1.cpp"
#line 42 "/usr/local/share/py-sip/QtCore/qabstractitemmodel.sip"
#include <qabstractitemmodel.h>
#line 890 "sipsolidpart1.cpp"
#line 48 "/usr/local/share/py-sip/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 893 "sipsolidpart1.cpp"
#line 46 "/usr/local/share/py-sip/QtCore/qurl.sip"
#include <qurl.h>
#line 896 "sipsolidpart1.cpp"
#line 46 "/usr/local/share/py-sip/QtCore/qlocale.sip"
#include <qlocale.h>
#line 899 "sipsolidpart1.cpp"
#line 45 "/usr/local/share/py-sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 902 "sipsolidpart1.cpp"
#line 42 "/usr/local/share/py-sip/QtCore/qthread.sip"
#include <qthread.h>
#line 905 "sipsolidpart1.cpp"
#line 46 "/usr/local/share/py-sip/QtCore/qregexp.sip"
#include <qregexp.h>
#line 908 "sipsolidpart1.cpp"
#line 42 "/usr/local/share/py-sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 911 "sipsolidpart1.cpp"


extern "C" {static PyObject *meth_Solid_Processor_deviceInterfaceType(PyObject *, PyObject *);}
static PyObject *meth_Solid_Processor_deviceInterfaceType(PyObject *,PyObject *sipArgs)
{
    int sipArgsParsed = 0;

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

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

            return sipConvertFromEnum(sipRes,sipType_Solid_DeviceInterface_Type);
        }
    }

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

    return NULL;
}


extern "C" {static PyObject *meth_Solid_Processor_number(PyObject *, PyObject *);}
static PyObject *meth_Solid_Processor_number(PyObject *sipSelf,PyObject *sipArgs)
{
    int sipArgsParsed = 0;

    {
        Solid::Processor *sipCpp;

        if (sipParseArgs(&sipArgsParsed,sipArgs,"B",&sipSelf,sipType_Solid_Processor,&sipCpp))
        {
            int sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->number();
            Py_END_ALLOW_THREADS

            return SIPLong_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipArgsParsed,sipName_Processor,sipName_number);

    return NULL;
}


extern "C" {static PyObject *meth_Solid_Processor_maxSpeed(PyObject *, PyObject *);}
static PyObject *meth_Solid_Processor_maxSpeed(PyObject *sipSelf,PyObject *sipArgs)
{
    int sipArgsParsed = 0;

    {
        Solid::Processor *sipCpp;

        if (sipParseArgs(&sipArgsParsed,sipArgs,"B",&sipSelf,sipType_Solid_Processor,&sipCpp))
        {
            int sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->maxSpeed();
            Py_END_ALLOW_THREADS

            return SIPLong_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipArgsParsed,sipName_Processor,sipName_maxSpeed);

    return NULL;
}


extern "C" {static PyObject *meth_Solid_Processor_canChangeFrequency(PyObject *, PyObject *);}
static PyObject *meth_Solid_Processor_canChangeFrequency(PyObject *sipSelf,PyObject *sipArgs)
{
    int sipArgsParsed = 0;

    {
        Solid::Processor *sipCpp;

        if (sipParseArgs(&sipArgsParsed,sipArgs,"B",&sipSelf,sipType_Solid_Processor,&sipCpp))
        {
            bool sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->canChangeFrequency();
            Py_END_ALLOW_THREADS

            return PyBool_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipArgsParsed,sipName_Processor,sipName_canChangeFrequency);

    return NULL;
}


extern "C" {static PyObject *meth_Solid_Processor_instructionSets(PyObject *, PyObject *);}
static PyObject *meth_Solid_Processor_instructionSets(PyObject *sipSelf,PyObject *sipArgs)
{
    int sipArgsParsed = 0;

    {
        Solid::Processor *sipCpp;

        if (sipParseArgs(&sipArgsParsed,sipArgs,"B",&sipSelf,sipType_Solid_Processor,&sipCpp))
        {
            Solid::Processor::InstructionSets *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new Solid::Processor::InstructionSets(sipCpp->instructionSets());
            Py_END_ALLOW_THREADS

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

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipArgsParsed,sipName_Processor,sipName_instructionSets);

    return NULL;
}


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

    if (targetType == sipType_Solid_Processor)
        return ptr;

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

    return NULL;
}


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

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

    Py_END_ALLOW_THREADS
}


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


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


static PyMethodDef methods_Solid_Processor[] = {
    {SIP_MLNAME_CAST(sipName_canChangeFrequency), meth_Solid_Processor_canChangeFrequency, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_deviceInterfaceType), meth_Solid_Processor_deviceInterfaceType, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_instructionSets), meth_Solid_Processor_instructionSets, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_maxSpeed), meth_Solid_Processor_maxSpeed, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_number), meth_Solid_Processor_number, METH_VARARGS, NULL}
};

static sipEnumMemberDef enummembers_Solid_Processor[] = {
    {sipName_AltiVec, Solid::Processor::AltiVec, 43},
    {sipName_Amd3DNow, Solid::Processor::Amd3DNow, 43},
    {sipName_IntelMmx, Solid::Processor::IntelMmx, 43},
    {sipName_IntelSse, Solid::Processor::IntelSse, 43},
    {sipName_IntelSse2, Solid::Processor::IntelSse2, 43},
    {sipName_IntelSse3, Solid::Processor::IntelSse3, 43},
    {sipName_IntelSse4, Solid::Processor::IntelSse4, 43},
    {sipName_NoExtensions, Solid::Processor::NoExtensions, 43},
};


pyqt4ClassTypeDef pyqt4Type_solid_Solid_Processor = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_SCC|SIP_TYPE_CLASS,
        sipNameNr_Solid__Processor,
        {0}
    },
    sipNameNr_Processor,
    -1,
    -1,
    {3, 255, 0},
    supers_Solid_Processor,
    0,
    5, methods_Solid_Processor,
    8, enummembers_Solid_Processor,
    0, 0,
    0,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_Solid_Processor,
    release_Solid_Processor,
    cast_Solid_Processor,
    0,
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    0,
    0
},
    0,
    &Solid::Processor::staticMetaObject,
    0,
    0
};

#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/predicate.sip"
#include <predicate.h>
#line 1156 "sipsolidpart1.cpp"

#line 46 "/usr/local/share/py-sip/QtCore/qstring.sip"
#include <qstring.h>
#line 1160 "sipsolidpart1.cpp"
#line 46 "/usr/local/share/py-sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 1163 "sipsolidpart1.cpp"
#line 54 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/deviceinterface.sip"
#include <deviceinterface.h>
#line 1166 "sipsolidpart1.cpp"
#line 61 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/powermanagement.sip"
#include <qset.h>
#include <powermanagement.h>
#line 74 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/predicate.sip"
#include <qset.h>
#include <powermanagement.h>
#line 1173 "sipsolidpart1.cpp"
#line 28 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/device.sip"
#include <device.h>
#line 1176 "sipsolidpart1.cpp"


extern "C" {static PyObject *meth_Solid_Predicate_isValid(PyObject *, PyObject *);}
static PyObject *meth_Solid_Predicate_isValid(PyObject *sipSelf,PyObject *sipArgs)
{
    int sipArgsParsed = 0;

    {
        Solid::Predicate *sipCpp;

        if (sipParseArgs(&sipArgsParsed,sipArgs,"B",&sipSelf,sipType_Solid_Predicate,&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(sipArgsParsed,sipName_Predicate,sipName_isValid);

    return NULL;
}


extern "C" {static PyObject *meth_Solid_Predicate_matches(PyObject *, PyObject *);}
static PyObject *meth_Solid_Predicate_matches(PyObject *sipSelf,PyObject *sipArgs)
{
    int sipArgsParsed = 0;

    {
        const Solid::Device * a0;
        Solid::Predicate *sipCpp;

        if (sipParseArgs(&sipArgsParsed,sipArgs,"BJ9",&sipSelf,sipType_Solid_Predicate,&sipCpp,sipType_Solid_Device,&a0))
        {
            bool sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->matches(*a0);
            Py_END_ALLOW_THREADS

            return PyBool_FromLong(sipRes);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipArgsParsed,sipName_Predicate,sipName_matches);

    return NULL;
}


extern "C" {static PyObject *meth_Solid_Predicate_usedTypes(PyObject *, PyObject *);}
static PyObject *meth_Solid_Predicate_usedTypes(PyObject *sipSelf,PyObject *sipArgs)
{
    int sipArgsParsed = 0;

    {
        Solid::Predicate *sipCpp;

        if (sipParseArgs(&sipArgsParsed,sipArgs,"B",&sipSelf,sipType_Solid_Predicate,&sipCpp))
        {
            QSet<Solid::DeviceInterface::Type> *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QSet<Solid::DeviceInterface::Type>(sipCpp->usedTypes());
            Py_END_ALLOW_THREADS

            PyObject *sipResObj = sipConvertFromType(sipRes,sipType_QSet_0500Solid_DeviceInterface_Type,NULL);
            delete sipRes;

            return sipResObj;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipArgsParsed,sipName_Predicate,sipName_usedTypes);

    return NULL;
}


extern "C" {static PyObject *meth_Solid_Predicate_toString(PyObject *, PyObject *);}
static PyObject *meth_Solid_Predicate_toString(PyObject *sipSelf,PyObject *sipArgs)
{
    int sipArgsParsed = 0;

    {
        Solid::Predicate *sipCpp;

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

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

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

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipArgsParsed,sipName_Predicate,sipName_toString);

    return NULL;
}


extern "C" {static PyObject *meth_Solid_Predicate_fromString(PyObject *, PyObject *);}
static PyObject *meth_Solid_Predicate_fromString(PyObject *,PyObject *sipArgs)
{
    int sipArgsParsed = 0;

    {
        const QString * a0;
        int a0State = 0;

        if (sipParseArgs(&sipArgsParsed,sipArgs,"J1",sipType_QString,&a0,&a0State))
        {
            Solid::Predicate *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new Solid::Predicate(Solid::Predicate::fromString(*a0));
            Py_END_ALLOW_THREADS

            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);

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

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipArgsParsed,sipName_Predicate,sipName_fromString);

    return NULL;
}


extern "C" {static PyObject *slot_Solid_Predicate___ior__(PyObject *sipSelf,PyObject *sipArg);}
static PyObject *slot_Solid_Predicate___ior__(PyObject *sipSelf,PyObject *sipArg)
{
    if (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_Solid_Predicate)))
    {
        Py_INCREF(Py_NotImplemented);
        return Py_NotImplemented;
    }

    Solid::Predicate *sipCpp = reinterpret_cast<Solid::Predicate *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_Solid_Predicate));

    if (!sipCpp)
        return 0;

    int sipArgsParsed = 0;

    {
        const Solid::Predicate * a0;

        if (sipParseArgs(&sipArgsParsed,sipArg,"1J9",sipType_Solid_Predicate,&a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->Solid::Predicate::operator|=(*a0);
            Py_END_ALLOW_THREADS

            Py_INCREF(sipSelf);
            return sipSelf;
        }
    }

    PyErr_Clear();

    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
}


extern "C" {static PyObject *slot_Solid_Predicate___or__(PyObject *sipArg0,PyObject *sipArg1);}
static PyObject *slot_Solid_Predicate___or__(PyObject *sipArg0,PyObject *sipArg1)
{
    int sipArgsParsed = 0;

    {
        Solid::Predicate * a0;
        const Solid::Predicate * a1;

        if (sipParsePair(&sipArgsParsed,sipArg0,sipArg1,"J9J9",sipType_Solid_Predicate,&a0,sipType_Solid_Predicate,&a1))
        {
            Solid::Predicate *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new Solid::Predicate((*a0 | *a1));
            Py_END_ALLOW_THREADS

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

    return sipPySlotExtend(&sipModuleAPI_solid,or_slot,NULL,sipArg0,sipArg1);
}


extern "C" {static PyObject *slot_Solid_Predicate___iand__(PyObject *sipSelf,PyObject *sipArg);}
static PyObject *slot_Solid_Predicate___iand__(PyObject *sipSelf,PyObject *sipArg)
{
    if (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_Solid_Predicate)))
    {
        Py_INCREF(Py_NotImplemented);
        return Py_NotImplemented;
    }

    Solid::Predicate *sipCpp = reinterpret_cast<Solid::Predicate *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_Solid_Predicate));

    if (!sipCpp)
        return 0;

    int sipArgsParsed = 0;

    {
        const Solid::Predicate * a0;

        if (sipParseArgs(&sipArgsParsed,sipArg,"1J9",sipType_Solid_Predicate,&a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->Solid::Predicate::operator&=(*a0);
            Py_END_ALLOW_THREADS

            Py_INCREF(sipSelf);
            return sipSelf;
        }
    }

    PyErr_Clear();

    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
}


extern "C" {static PyObject *slot_Solid_Predicate___and__(PyObject *sipArg0,PyObject *sipArg1);}
static PyObject *slot_Solid_Predicate___and__(PyObject *sipArg0,PyObject *sipArg1)
{
    int sipArgsParsed = 0;

    {
        Solid::Predicate * a0;
        const Solid::Predicate * a1;

        if (sipParsePair(&sipArgsParsed,sipArg0,sipArg1,"J9J9",sipType_Solid_Predicate,&a0,sipType_Solid_Predicate,&a1))
        {
            Solid::Predicate *sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new Solid::Predicate((*a0 & *a1));
            Py_END_ALLOW_THREADS

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

    return sipPySlotExtend(&sipModuleAPI_solid,and_slot,NULL,sipArg0,sipArg1);
}


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

    return NULL;
}


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

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

    Py_END_ALLOW_THREADS
}


extern "C" {static void assign_Solid_Predicate(void *, const void*);}
static void assign_Solid_Predicate(void *sipDst, const void *sipSrc)
{
    *reinterpret_cast<Solid::Predicate *>(sipDst) = *reinterpret_cast<const Solid::Predicate *>(sipSrc);
}


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


extern "C" {static void *init_Solid_Predicate(sipSimpleWrapper *, PyObject *, PyObject **, int *);}
static void *init_Solid_Predicate(sipSimpleWrapper *, PyObject *sipArgs, PyObject **, int *sipArgsParsed)
{
    Solid::Predicate *sipCpp = 0;

    if (!sipCpp)
    {
        if (sipParseArgs(sipArgsParsed,sipArgs,""))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new Solid::Predicate();
            Py_END_ALLOW_THREADS
        }
    }

    if (!sipCpp)
    {
        const Solid::Predicate * a0;

        if (sipParseArgs(sipArgsParsed,sipArgs,"J9",sipType_Solid_Predicate,&a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new Solid::Predicate(*a0);
            Py_END_ALLOW_THREADS
        }
    }

    if (!sipCpp)
    {
        const QString * a0;
        int a0State = 0;
        const QString * a1;
        int a1State = 0;
        const QVariant * a2;
        int a2State = 0;
        Solid::Predicate::ComparisonOperator a3 = Solid::Predicate::Equals;

        if (sipParseArgs(sipArgsParsed,sipArgs,"J1J1J1|E",sipType_QString,&a0,&a0State,sipType_QString,&a1,&a1State,sipType_QVariant,&a2,&a2State,sipType_Solid_Predicate_ComparisonOperator,&a3))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new Solid::Predicate(*a0,*a1,*a2,a3);
            Py_END_ALLOW_THREADS

            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);
            sipReleaseType(const_cast<QVariant *>(a2),sipType_QVariant,a2State);
        }
    }

    if (!sipCpp)
    {
        Solid::DeviceInterface::Type a0;

        if (sipParseArgs(sipArgsParsed,sipArgs,"E",sipType_Solid_DeviceInterface_Type,&a0))
        {
#line 46 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/predicate.sip"
Py_BEGIN_ALLOW_THREADS
    sipCpp = new Solid::Predicate (a0);
    Py_END_ALLOW_THREADS
#line 1544 "sipsolidpart1.cpp"
        }
    }

    if (!sipCpp)
    {
        const QString * a0;
        int a0State = 0;

        if (sipParseArgs(sipArgsParsed,sipArgs,"J1",sipType_QString,&a0,&a0State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new Solid::Predicate(*a0);
            Py_END_ALLOW_THREADS

            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);
        }
    }

    return sipCpp;
}


/* Define this type's Python slots. */
static sipPySlotDef slots_Solid_Predicate[] = {
    {(void *)slot_Solid_Predicate___ior__, ior_slot},
    {(void *)slot_Solid_Predicate___or__, or_slot},
    {(void *)slot_Solid_Predicate___iand__, iand_slot},
    {(void *)slot_Solid_Predicate___and__, and_slot},
    {0, (sipPySlotType)0}
};


static PyMethodDef methods_Solid_Predicate[] = {
    {SIP_MLNAME_CAST(sipName_fromString), meth_Solid_Predicate_fromString, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_isValid), meth_Solid_Predicate_isValid, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_matches), meth_Solid_Predicate_matches, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_toString), meth_Solid_Predicate_toString, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_usedTypes), meth_Solid_Predicate_usedTypes, METH_VARARGS, NULL}
};

static sipEnumMemberDef enummembers_Solid_Predicate[] = {
    {sipName_Equals, Solid::Predicate::Equals, 41},
    {sipName_Mask, Solid::Predicate::Mask, 41},
};


pyqt4ClassTypeDef pyqt4Type_solid_Solid_Predicate = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_CLASS,
        sipNameNr_Solid__Predicate,
        {0}
    },
    sipNameNr_Predicate,
    sipNameNr_PyQt4_QtCore_pyqtWrapperType,
    -1,
    {3, 255, 0},
    0,
    slots_Solid_Predicate,
    5, methods_Solid_Predicate,
    2, enummembers_Solid_Predicate,
    0, 0,
    init_Solid_Predicate,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_Solid_Predicate,
    release_Solid_Predicate,
    cast_Solid_Predicate,
    0,
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    0,
    0
},
    assign_Solid_Predicate,
    0,
    0,
    0
};

#line 61 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/powermanagement.sip"
#include <qset.h>
#include <powermanagement.h>
#line 74 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/predicate.sip"
#include <qset.h>
#include <powermanagement.h>
#line 1642 "sipsolidpart1.cpp"

#line 54 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/deviceinterface.sip"
#include <deviceinterface.h>
#line 1646 "sipsolidpart1.cpp"


extern "C" {static void assign_QSet_0500Solid_DeviceInterface_Type(void *, const void*);}
static void assign_QSet_0500Solid_DeviceInterface_Type(void *sipDst, const void *sipSrc)
{
    *reinterpret_cast<QSet<Solid::DeviceInterface::Type> *>(sipDst) = *reinterpret_cast<const QSet<Solid::DeviceInterface::Type> *>(sipSrc);
}


/* Call the mapped type's destructor. */
extern "C" {static void release_QSet_0500Solid_DeviceInterface_Type(void *, int);}
static void release_QSet_0500Solid_DeviceInterface_Type(void *ptr, int)
{
    Py_BEGIN_ALLOW_THREADS
    delete reinterpret_cast<QSet<Solid::DeviceInterface::Type> *>(ptr);
    Py_END_ALLOW_THREADS
}



extern "C" {static int convertTo_QSet_0500Solid_DeviceInterface_Type(PyObject *, void **, int *, PyObject *);}
static int convertTo_QSet_0500Solid_DeviceInterface_Type(PyObject *sipPy,void **sipCppPtrV,int *sipIsErr,PyObject *sipTransferObj)
{
    QSet<Solid::DeviceInterface::Type> **sipCppPtr = reinterpret_cast<QSet<Solid::DeviceInterface::Type> **>(sipCppPtrV);

#line 109 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/predicate.sip"
    // Check the type if that is all that is required.
    if (sipIsErr == NULL)
    {
        if (!PyList_Check(sipPy))
            return 0;
    }

    // Check the type if that is all that is required.
    if (sipIsErr == NULL)
    {
        if (!PyList_Check(sipPy))
            return 0;
    }

    QSet<Solid::DeviceInterface::Type> *qs = new QSet<Solid::DeviceInterface::Type>;
 
    for (int i = 0; i < PyList_GET_SIZE(sipPy); ++i)
    {
        Solid::DeviceInterface::Type t = (Solid::DeviceInterface::Type)PyInt_AS_LONG (PyList_GET_ITEM (sipPy, i));
        *qs << t;

    }
 
    *sipCppPtr = qs;
 
    return sipGetState(sipTransferObj);
#line 1699 "sipsolidpart1.cpp"
}


extern "C" {static PyObject *convertFrom_QSet_0500Solid_DeviceInterface_Type(void *, PyObject *);}
static PyObject *convertFrom_QSet_0500Solid_DeviceInterface_Type(void *sipCppV,PyObject *)
{
   QSet<Solid::DeviceInterface::Type> *sipCpp = reinterpret_cast<QSet<Solid::DeviceInterface::Type> *>(sipCppV);

#line 79 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/predicate.sip"
    // Create the list.
    PyObject *l;

    if ((l = PyList_New(sipCpp->size())) == NULL)
        return NULL;

    // Set the list elements.
    QSet<Solid::DeviceInterface::Type> set = *sipCpp;
    int i = 0;
    foreach (Solid::DeviceInterface::Type value, set)
    {
        PyObject *obj = PyInt_FromLong ((long) value);
        if (obj == NULL || PyList_SET_ITEM (l, i, obj) < 0)
        {
            Py_DECREF(l);

            if (obj)
                Py_DECREF(obj);

            return NULL;
        }

        Py_DECREF(obj);
        i++;
    }
   
    return l;
#line 1736 "sipsolidpart1.cpp"
}


pyqt4MappedTypeDef pyqt4MappedTypeDef_solid_QSet_0500Solid_DeviceInterface_Type = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_MAPPED,
        sipNameNr_346,
        {0}
    },
    release_QSet_0500Solid_DeviceInterface_Type,
    convertTo_QSet_0500Solid_DeviceInterface_Type,
    convertFrom_QSet_0500Solid_DeviceInterface_Type
},
    assign_QSet_0500Solid_DeviceInterface_Type
};


extern "C" {static void assign_QSet_0500Solid_PowerManagement_SleepState(void *, const void*);}
static void assign_QSet_0500Solid_PowerManagement_SleepState(void *sipDst, const void *sipSrc)
{
    *reinterpret_cast<QSet<Solid::PowerManagement::SleepState> *>(sipDst) = *reinterpret_cast<const QSet<Solid::PowerManagement::SleepState> *>(sipSrc);
}


/* Call the mapped type's destructor. */
extern "C" {static void release_QSet_0500Solid_PowerManagement_SleepState(void *, int);}
static void release_QSet_0500Solid_PowerManagement_SleepState(void *ptr, int)
{
    Py_BEGIN_ALLOW_THREADS
    delete reinterpret_cast<QSet<Solid::PowerManagement::SleepState> *>(ptr);
    Py_END_ALLOW_THREADS
}



extern "C" {static int convertTo_QSet_0500Solid_PowerManagement_SleepState(PyObject *, void **, int *, PyObject *);}
static int convertTo_QSet_0500Solid_PowerManagement_SleepState(PyObject *sipPy,void **sipCppPtrV,int *sipIsErr,PyObject *sipTransferObj)
{
    QSet<Solid::PowerManagement::SleepState> **sipCppPtr = reinterpret_cast<QSet<Solid::PowerManagement::SleepState> **>(sipCppPtrV);

#line 96 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/powermanagement.sip"
    // Check the type if that is all that is required.
    if (sipIsErr == NULL)
    {
        if (!PyList_Check(sipPy))
            return 0;
    }

    // Check the type if that is all that is required.
    if (sipIsErr == NULL)
    {
        if (!PyList_Check(sipPy))
            return 0;
    }

    QSet<Solid::PowerManagement::SleepState> *qs = new QSet<Solid::PowerManagement::SleepState>;
 
    for (int i = 0; i < PyList_GET_SIZE(sipPy); ++i)
    {
        Solid::PowerManagement::SleepState t = (Solid::PowerManagement::SleepState)PyInt_AS_LONG (PyList_GET_ITEM (sipPy, i));
        *qs << t;

    }
 
    *sipCppPtr = qs;
 
    return sipGetState(sipTransferObj);
#line 1808 "sipsolidpart1.cpp"
}


extern "C" {static PyObject *convertFrom_QSet_0500Solid_PowerManagement_SleepState(void *, PyObject *);}
static PyObject *convertFrom_QSet_0500Solid_PowerManagement_SleepState(void *sipCppV,PyObject *)
{
   QSet<Solid::PowerManagement::SleepState> *sipCpp = reinterpret_cast<QSet<Solid::PowerManagement::SleepState> *>(sipCppV);

#line 66 "/work/a/ports/devel/kdebindings4-python-pykde4/work/kdebindings-4.3.1/python/pykde4/sip/solid/powermanagement.sip"
    // Create the list.
    PyObject *l;

    if ((l = PyList_New(sipCpp->size())) == NULL)
        return NULL;

    // Set the list elements.
    QSet<Solid::PowerManagement::SleepState> set = *sipCpp;
    int i = 0;
    foreach (Solid::PowerManagement::SleepState value, set)
    {
        PyObject *obj = PyInt_FromLong ((long) value);
        if (obj == NULL || PyList_SET_ITEM (l, i, obj) < 0)
        {
            Py_DECREF(l);

            if (obj)
                Py_DECREF(obj);

            return NULL;
        }

        Py_DECREF(obj);
        i++;
    }
   
    return l;
#line 1845 "sipsolidpart1.cpp"
}


pyqt4MappedTypeDef pyqt4MappedTypeDef_solid_QSet_0500Solid_PowerManagement_SleepState = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_MAPPED,
        sipNameNr_85,
        {0}
    },
    release_QSet_0500Solid_PowerManagement_SleepState,
    convertTo_QSet_0500Solid_PowerManagement_SleepState,
    convertFrom_QSet_0500Solid_PowerManagement_SleepState
},
    assign_QSet_0500Solid_PowerManagement_SleepState
};
