]> Git Repo - VerusCoin.git/blob - src/qt/paymentrequestplus.h
Merge src/leveldb changes for LevelDB 1.13
[VerusCoin.git] / src / qt / paymentrequestplus.h
1 #ifndef PAYMENTREQUESTPLUS_H
2 #define PAYMENTREQUESTPLUS_H
3
4 #include <QByteArray>
5 #include <QList>
6 #include <QString>
7
8 #include "base58.h"
9 #include "paymentrequest.pb.h"
10
11 //
12 // Wraps dumb protocol buffer paymentRequest
13 // with extra methods
14 //
15
16 class PaymentRequestPlus
17 {
18 public:
19     PaymentRequestPlus() { }
20
21     bool parse(const QByteArray& data);
22     bool SerializeToString(string* output) const;
23
24     bool IsInitialized() const;
25     QString getPKIType() const;
26     // Returns true if merchant's identity is authenticated, and
27     // returns human-readable merchant identity in merchant
28     bool getMerchant(X509_STORE* certStore, QString& merchant) const;
29
30     // Returns list of outputs, amount
31     QList<std::pair<CScript,qint64> > getPayTo() const;
32
33     const payments::PaymentDetails& getDetails() const { return details; }
34
35 private:
36     payments::PaymentRequest paymentRequest;
37     payments::PaymentDetails details;
38 };
39
40 #endif // PAYMENTREQUESTPLUS_H
41
This page took 0.02596 seconds and 4 git commands to generate.