
// Auto generated

#ifndef QMARGINS_H_WRAPPER
#define QMARGINS_H_WRAPPER

// include header:
//#include "header_h.h"

#include "../RJSHelper.h"


#include "RJSWrapperObj.h"

#include <QQmlEngine>

#include "RJSType.h"

#include <QMargins>

// static functions implementation in singleton wrapper:

// wrapper class for QMargins
class QTJSAPI_EXPORT QMargins_Wrapper : public RJSWrapperObj {


    Q_OBJECT
    QML_INTERFACE


private:
    // disable copy constructor:
    QMargins_Wrapper(const QMargins_Wrapper&);

public:
    // initialization of QMargins:
    static void init(RJSApi& handler);


    static QMargins* castToBase(void* vp, /*RJSType ID*/ int t) {

        // check if pointer points to derrived type:


        // hook for modules to cast from other types to base QMargins:
        for (int i=0; i<basecasters_QMargins.length(); i++) {
            RJSBasecaster_QMargins* basecaster = basecasters_QMargins[i];
            QMargins* ret = basecaster->castToBase(t, vp);
            if (ret!=nullptr) {
                return ret;
            }
        }

        // object is a pointer to base class QMargins:
        if (t==RJSType_QMargins::getIdStatic()) {
            return (QMargins*)vp;
        }

        qWarning() << "QMargins_Wrapper::castToBase: type not found: " << RJSHelper::getTypeName(t);

        return nullptr;

    }

    static QMargins* getWrappedBase(RJSWrapper* wrapper) {
        int t = wrapper->getWrappedType();
        void* vp = wrapper->getWrappedVoid();
        if (vp==nullptr) {
            //qWarning() << "getWrapped_QMargins*: wrapper wraps NULL";
        }

        QMargins* ret = castToBase(vp, t);
        if (ret==nullptr && vp!=nullptr) {
            qWarning() << "QMargins*_Wrapper::getWrappedBase: extracted type " << t << "from wrapper is NULL";
        }
        return ret;
    }

    /*
    // special constructor used as prototype:

          Q_INVOKABLE
          QMargins_Wrapper(QJSEngine* e);

    */


    // special constructor to wrap existing object:

    //Q_INVOKABLE
    QMargins_Wrapper(RJSApi& h, QMargins* o, bool wrappedCreated);


    // destructor:

    virtual ~QMargins_Wrapper();

    // initialization of signal forwarding

    void initConnections();


    // constructors:

    // Class: QMargins
    // Function:
    // Source:
    // Static: false
    // Parameters: 4
    // preceding Parameters: -1

public:
    Q_INVOKABLE
    QMargins_Wrapper

    (


        // RJSApi:
        QObject* h

        ,

        const QJSValue&
        a1
        = QJSValue()
          ,
        const QJSValue&
        a2
        = QJSValue()
          ,
        const QJSValue&
        a3
        = QJSValue()
          ,
        const QJSValue&
        a4
        = QJSValue()

    )

    ;


    // non-static functions:

    // Class: QMargins
    // Function: isNull
    // Source:
    // Static: false
    // Parameters: 0
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    isNull
    (


    )

    const

    ;

    // Class: QMargins
    // Function: left
    // Source:
    // Static: false
    // Parameters: 0
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    left
    (


    )

    const

    ;

    // Class: QMargins
    // Function: top
    // Source:
    // Static: false
    // Parameters: 0
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    top
    (


    )

    const

    ;

    // Class: QMargins
    // Function: right
    // Source:
    // Static: false
    // Parameters: 0
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    right
    (


    )

    const

    ;

    // Class: QMargins
    // Function: bottom
    // Source:
    // Static: false
    // Parameters: 0
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    bottom
    (


    )

    const

    ;

    // Class: QMargins
    // Function: setLeft
    // Source:
    // Static: false
    // Parameters: 1
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    setLeft
    (


        const QJSValue&
        a1
        = QJSValue()

    )

    ;

    // Class: QMargins
    // Function: setTop
    // Source:
    // Static: false
    // Parameters: 1
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    setTop
    (


        const QJSValue&
        a1
        = QJSValue()

    )

    ;

    // Class: QMargins
    // Function: setRight
    // Source:
    // Static: false
    // Parameters: 1
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    setRight
    (


        const QJSValue&
        a1
        = QJSValue()

    )

    ;

    // Class: QMargins
    // Function: setBottom
    // Source:
    // Static: false
    // Parameters: 1
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    setBottom
    (


        const QJSValue&
        a1
        = QJSValue()

    )

    ;

    // destroy function for non-copyable objects:
    Q_INVOKABLE void destr() {
        if (wrapped!=nullptr) {

            delete wrapped;

            wrapped = nullptr;
        }

    }


    //public:
    // set engine:
    //Q_INVOKABLE void setHandler(RJSApi* h) {
    //  RJSWrapperObj::setHandler(h);
    //}


    // member functions for static properties, forward to static function



    // protected overwritten functions / events and their public invokable counterparts:

public:

    // get type of wrapped object:
    Q_INVOKABLE
    virtual /*RJSType ID*/ int getWrappedType() const {
        return RJSType_QMargins::getIdStatic();
    }

    // return true if wrapped object is owned by C++ (not deleted):
    Q_INVOKABLE
    virtual bool isCppOwnership() const {

        return false;

    }

    // get wrapped object:
    QMargins* getWrapped() {
        if (wrapped!=nullptr) {
            return wrapped;
        }

        return nullptr;
    }

    // get wrapped object (const):
    QMargins* getWrapped() const {
        if (wrapped!=nullptr) {
            return wrapped;
        }

        return nullptr;
    }

    // get wrapped object as void*:
    virtual void* getWrappedVoid() {
        if (wrapped!=nullptr) {
            return wrapped;
        }

        return nullptr;
    }



    bool hasWrapped() const {
        return wrapped!=nullptr

               ;
    }

    Q_INVOKABLE
    bool isNullWrapper() const {
        return !hasWrapped();
    }

    Q_INVOKABLE
    unsigned long long int getAddress() const {
        if (wrapped!=nullptr) {
            return (unsigned long long int)wrapped;
        }

        return (unsigned long long int)0;
    }



    //public slots:
    //void slotDestroyed(QObject* obj) {
    //  qDebug() << "destroying QObject:" << (long int)obj;
    //}



private:
    // wrapped object:
    QMargins* wrapped;



    bool wrappedCreated;

private:
    // list of registered base casters for this wrapper class:
    static QList<RJSBasecaster_QMargins*> basecasters_QMargins;

public:
    static void registerBasecaster_QMargins(RJSBasecaster_QMargins* bc) {
        basecasters_QMargins.append(bc);
    }

};

Q_DECLARE_METATYPE(QMargins_Wrapper*)

Q_DECLARE_INTERFACE(QMargins_Wrapper, "org.qcad.QMargins_Wrapper")


#include <QQmlEngine>

#include "RJSType.h"

#include <QMarginsF>

// static functions implementation in singleton wrapper:

// wrapper class for QMarginsF
class QTJSAPI_EXPORT QMarginsF_Wrapper : public RJSWrapperObj {


    Q_OBJECT
    QML_INTERFACE


private:
    // disable copy constructor:
    QMarginsF_Wrapper(const QMarginsF_Wrapper&);

public:
    // initialization of QMarginsF:
    static void init(RJSApi& handler);


    static QMarginsF* castToBase(void* vp, /*RJSType ID*/ int t) {

        // check if pointer points to derrived type:


        // hook for modules to cast from other types to base QMarginsF:
        for (int i=0; i<basecasters_QMarginsF.length(); i++) {
            RJSBasecaster_QMarginsF* basecaster = basecasters_QMarginsF[i];
            QMarginsF* ret = basecaster->castToBase(t, vp);
            if (ret!=nullptr) {
                return ret;
            }
        }

        // object is a pointer to base class QMarginsF:
        if (t==RJSType_QMarginsF::getIdStatic()) {
            return (QMarginsF*)vp;
        }

        qWarning() << "QMarginsF_Wrapper::castToBase: type not found: " << RJSHelper::getTypeName(t);

        return nullptr;

    }

    static QMarginsF* getWrappedBase(RJSWrapper* wrapper) {
        int t = wrapper->getWrappedType();
        void* vp = wrapper->getWrappedVoid();
        if (vp==nullptr) {
            //qWarning() << "getWrapped_QMarginsF*: wrapper wraps NULL";
        }

        QMarginsF* ret = castToBase(vp, t);
        if (ret==nullptr && vp!=nullptr) {
            qWarning() << "QMarginsF*_Wrapper::getWrappedBase: extracted type " << t << "from wrapper is NULL";
        }
        return ret;
    }

    /*
    // special constructor used as prototype:

          Q_INVOKABLE
          QMarginsF_Wrapper(QJSEngine* e);

    */


    // special constructor to wrap existing object:

    //Q_INVOKABLE
    QMarginsF_Wrapper(RJSApi& h, QMarginsF* o, bool wrappedCreated);


    // destructor:

    virtual ~QMarginsF_Wrapper();

    // initialization of signal forwarding

    void initConnections();


    // constructors:

    // Class: QMarginsF
    // Function:
    // Source:
    // Static: false
    // Parameters: 4
    // preceding Parameters: -1

public:
    Q_INVOKABLE
    QMarginsF_Wrapper

    (


        // RJSApi:
        QObject* h

        ,

        const QJSValue&
        a1
        = QJSValue()
          ,
        const QJSValue&
        a2
        = QJSValue()
          ,
        const QJSValue&
        a3
        = QJSValue()
          ,
        const QJSValue&
        a4
        = QJSValue()

    )

    ;


    // non-static functions:

    // Class: QMarginsF
    // Function: isNull
    // Source:
    // Static: false
    // Parameters: 0
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    isNull
    (


    )

    const

    ;

    // Class: QMarginsF
    // Function: left
    // Source:
    // Static: false
    // Parameters: 0
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    left
    (


    )

    const

    ;

    // Class: QMarginsF
    // Function: top
    // Source:
    // Static: false
    // Parameters: 0
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    top
    (


    )

    const

    ;

    // Class: QMarginsF
    // Function: right
    // Source:
    // Static: false
    // Parameters: 0
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    right
    (


    )

    const

    ;

    // Class: QMarginsF
    // Function: bottom
    // Source:
    // Static: false
    // Parameters: 0
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    bottom
    (


    )

    const

    ;

    // Class: QMarginsF
    // Function: setLeft
    // Source:
    // Static: false
    // Parameters: 1
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    setLeft
    (


        const QJSValue&
        a1
        = QJSValue()

    )

    ;

    // Class: QMarginsF
    // Function: setTop
    // Source:
    // Static: false
    // Parameters: 1
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    setTop
    (


        const QJSValue&
        a1
        = QJSValue()

    )

    ;

    // Class: QMarginsF
    // Function: setRight
    // Source:
    // Static: false
    // Parameters: 1
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    setRight
    (


        const QJSValue&
        a1
        = QJSValue()

    )

    ;

    // Class: QMarginsF
    // Function: setBottom
    // Source:
    // Static: false
    // Parameters: 1
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    setBottom
    (


        const QJSValue&
        a1
        = QJSValue()

    )

    ;

    // Class: QMarginsF
    // Function: toMargins
    // Source:
    // Static: false
    // Parameters: 0
    // preceding Parameters: -1

public:
    Q_INVOKABLE

    QJSValue
    toMargins
    (


    )

    const

    ;

    // destroy function for non-copyable objects:
    Q_INVOKABLE void destr() {
        if (wrapped!=nullptr) {

            delete wrapped;

            wrapped = nullptr;
        }

    }


    //public:
    // set engine:
    //Q_INVOKABLE void setHandler(RJSApi* h) {
    //  RJSWrapperObj::setHandler(h);
    //}


    // member functions for static properties, forward to static function



    // protected overwritten functions / events and their public invokable counterparts:

public:

    // get type of wrapped object:
    Q_INVOKABLE
    virtual /*RJSType ID*/ int getWrappedType() const {
        return RJSType_QMarginsF::getIdStatic();
    }

    // return true if wrapped object is owned by C++ (not deleted):
    Q_INVOKABLE
    virtual bool isCppOwnership() const {

        return false;

    }

    // get wrapped object:
    QMarginsF* getWrapped() {
        if (wrapped!=nullptr) {
            return wrapped;
        }

        return nullptr;
    }

    // get wrapped object (const):
    QMarginsF* getWrapped() const {
        if (wrapped!=nullptr) {
            return wrapped;
        }

        return nullptr;
    }

    // get wrapped object as void*:
    virtual void* getWrappedVoid() {
        if (wrapped!=nullptr) {
            return wrapped;
        }

        return nullptr;
    }



    bool hasWrapped() const {
        return wrapped!=nullptr

               ;
    }

    Q_INVOKABLE
    bool isNullWrapper() const {
        return !hasWrapped();
    }

    Q_INVOKABLE
    unsigned long long int getAddress() const {
        if (wrapped!=nullptr) {
            return (unsigned long long int)wrapped;
        }

        return (unsigned long long int)0;
    }



    //public slots:
    //void slotDestroyed(QObject* obj) {
    //  qDebug() << "destroying QObject:" << (long int)obj;
    //}



private:
    // wrapped object:
    QMarginsF* wrapped;



    bool wrappedCreated;

private:
    // list of registered base casters for this wrapper class:
    static QList<RJSBasecaster_QMarginsF*> basecasters_QMarginsF;

public:
    static void registerBasecaster_QMarginsF(RJSBasecaster_QMarginsF* bc) {
        basecasters_QMarginsF.append(bc);
    }

};

Q_DECLARE_METATYPE(QMarginsF_Wrapper*)

Q_DECLARE_INTERFACE(QMarginsF_Wrapper, "org.qcad.QMarginsF_Wrapper")


#endif

