AzureEvent.h 882 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
#ifndef AZUREEVENT_H
#define AZUREEVENT_H

#include <QObject>

class CAzureEvent : public QObject
{
    Q_OBJECT
    Q_PROPERTY( QString userName READ userName WRITE setUserName NOTIFY userNameChanged)
    Q_PROPERTY( float cost READ cost WRITE setCost NOTIFY costChanged )
    Q_PROPERTY( float charging READ charging WRITE setCharging NOTIFY chargingChanged )
public:
    CAzureEvent( );

    float cost();
    void setCost( float cost );
    QString userName();
    void setUserName( QString str );

    float charging();
    void setCharging( float charge );

    Q_INVOKABLE void sendEvent();
    Q_INVOKABLE void resetAll();

Q_SIGNALS:
    void userNameChanged();
    void costChanged();
    void chargingChanged();
    void signalSendEvent(const QByteArray&);
public:
    QString mUserName;
    float mCost;
    float mCharging;
    int mCounter;
};

#endif // AZUREEVENT_H