MidlePayQml 0.0.4
MiddlePay QML module
midlePay.hpp
1 #pragma once
2 #include"qaddr_bundle.hpp"
3 #include"crypto/qslip10.hpp"
4 #include"client/qclient.hpp"
5 #include"client/qclientMQTT.hpp"
6 #include<QObject>
7 
8 #include<QString>
9 #include<QByteArray>
10 #include <QtQml/qqmlregistration.h>
11 
12 #include <QtCore/QtGlobal>
13 
14 //foo namespace to force the linker to link the backing library composed only of qml files
15 namespace fooMidlePay
16 {
18 };
19 
20 
21 #if defined(WINDOWS_ACCOU)
22 # define MIDLE_EXPORT Q_DECL_EXPORT
23 #else
24 #define MIDLE_EXPORT Q_DECL_IMPORT
25 #endif
26 
27 using namespace qiota;
28 using namespace qiota::qblocks;
29 using namespace qcrypto;
30 
31 class MIDLE_EXPORT MidlePay : public QObject
32 {
33  Q_OBJECT
34 
35  Q_PROPERTY(QString address MEMBER m_address NOTIFY addressChanged)
36  Q_PROPERTY(bool pass MEMBER m_pass NOTIFY passChanged)
37  Q_PROPERTY(QString message MEMBER m_message NOTIFY messageChanged)
38  Q_PROPERTY(QUrl nodeaddr MEMBER m_naddr NOTIFY naddrChanged)
39  Q_PROPERTY(QString initTag MEMBER m_initTag NOTIFY initTagChanged)
40  Q_PROPERTY(quint64 amount MEMBER m_amount NOTIFY amountChanged)
41 
42  QML_ELEMENT
43 
44  public:
45  MidlePay(QObject *parent = nullptr);
46 
47 signals:
49  void passChanged();
50  void naddrChanged();
53  void amountChanged();
54  private:
55  bool checkTransfer(Node_output out);
56  QString m_address,m_message,m_tag,m_initTag;
57  QUrl m_naddr;
58  bool m_pass;
59  Client* rest_client;
60  ClientMqtt * mqtt_client;
61  quint64 m_amount;
62 
63 };
64 
Definition: midlePay.hpp:32
void messageChanged()
void initTagChanged()
void naddrChanged()
void addressChanged()
void passChanged()
MidlePay(QObject *parent=nullptr)
void amountChanged()
Definition: qclientMQTT.hpp:33
Definition: qclient.hpp:20
Definition: qnode_outputs.hpp:9
Definition: midlePay.hpp:16
QString fooPrint(void)
Definition: qslip10.hpp:9
Definition: carray.hpp:22
Definition: qbigint.hpp:7