MagicSmoke
$VERSION$
|
pay for an order with money/credit card/...; see UseVoucher for using a voucher to pay More...
#include <srcMTOrderPay.h>
Public Member Functions | |
MTOrderPay () | |
default constructor: generates an invalid transaction More... | |
MTOrderPay (const MTOrderPay &) | |
copy constructor: the two copies share their state More... | |
virtual | ~MTOrderPay () |
deletes this instance More... | |
Q_SLOT Nullable< qint64 > | getamount () const |
the amount actually taken, it is between 0 and at maximum the amount due for the order, it is never above the offered amount More... | |
Q_SLOT Nullable< MOOrder > | getorder () const |
fresh copy of the order More... | |
MTOrderPay & | operator= (const MTOrderPay &) |
copy assignment: the copy shares the state of the original object More... | |
Static Public Member Functions | |
static MTOrderPay | asyncQuery (const qint64 &aorderid, const qint64 &aamount, const QString &apaytype, const QString &apaydata, QString iface="MagicSmoke") |
emits the query over the network and returns the transaction object, use isFinished() to check for the transaction's state More... | |
static MTOrderPay | query (const qint64 &aorderid, const qint64 &aamount, const QString &apaytype, const QString &apaydata, QString iface="MagicSmoke") |
emits the query over the network and returns the finished transaction object More... | |
Static Public Member Functions inherited from MTransaction | |
static void | setStartStopActions (const MTStartStop &start, const MTStartStop &stop) |
set actions to be executed at start/stop More... | |
Protected Member Functions | |
MTOrderPay (const qint64 &aorderid, const qint64 &aamount, const QString &apaytype, const QString &apaydata, QString iface) | |
generates an instance from its properties More... | |
virtual void | endQuery () |
Protected Member Functions inherited from MTransaction | |
MTransaction (QString iface=QString()) | |
internal: construct the transaction More... | |
MTransaction (const WTransaction &) | |
internal: copy the transaction More... | |
MTransaction (const MTransaction &) | |
internal: copy the transaction More... | |
QByteArray | executeQuery (QString, QByteArray) |
internal: extend executeQuery to show a wait cursor More... | |
Friends | |
class | MTOrderPay_Private |
pay for an order with money/credit card/...; see UseVoucher for using a voucher to pay
|
explicitprotected |
generates an instance from its properties
aorderid | The order to be paid |
aamount | amount offered, it must be positive |
apaytype | the type of payment |
apaydata | additional data, like card number or date of bank transaction |
iface | ID of the interface that the transaction will be sent on |
References MTOrderPay_Private::in_amount, MTOrderPay_Private::in_orderid, MTOrderPay_Private::in_paydata, MTOrderPay_Private::in_paytype, and MTOrderPay_Private.
MTOrderPay::MTOrderPay | ( | ) |
default constructor: generates an invalid transaction
References MTOrderPay_Private.
MTOrderPay::MTOrderPay | ( | const MTOrderPay & | t | ) |
copy constructor: the two copies share their state
References MTOrderPay_Private::attach().
|
virtual |
deletes this instance
References MTOrderPay_Private::detach().
|
static |
emits the query over the network and returns the transaction object, use isFinished() to check for the transaction's state
aorderid | The order to be paid |
aamount | amount offered, it must be positive |
apaytype | the type of payment |
apaydata | additional data, like card number or date of bank transaction |
iface | ID of the interface that the transaction will be sent on |
|
protectedvirtual |
Nullable< qint64 > MTOrderPay::getamount | ( | ) | const |
the amount actually taken, it is between 0 and at maximum the amount due for the order, it is never above the offered amount
References MTOrderPay_Private::out_amount.
Nullable< MOOrder > MTOrderPay::getorder | ( | ) | const |
fresh copy of the order
References MTOrderPay_Private::out_order.
MTOrderPay & MTOrderPay::operator= | ( | const MTOrderPay & | t | ) |
copy assignment: the copy shares the state of the original object
References MTOrderPay_Private::attach(), and MTOrderPay_Private::detach().
|
static |
emits the query over the network and returns the finished transaction object
aorderid | The order to be paid |
aamount | amount offered, it must be positive |
apaytype | the type of payment |
apaydata | additional data, like card number or date of bank transaction |
iface | ID of the interface that the transaction will be sent on |
Referenced by MInterface::queryOrderPay().
|
friend |
Referenced by MTOrderPay().