MagicSmoke  $VERSION$
MTCreateReservation Class Reference

Reservations are orders that are not executed right away. They may only contain tickets that block some seats for a limited time. They cannot contain any shopping items or vouchers. More...

#include <srcMTCreateReservation.h>

Inheritance diagram for MTCreateReservation:
MTransaction

Public Member Functions

 MTCreateReservation ()
 default constructor: generates an invalid transaction More...
 
 MTCreateReservation (const MTCreateReservation &)
 copy constructor: the two copies share their state More...
 
virtual ~MTCreateReservation ()
 deletes this instance More...
 
Q_SLOT Nullable< MOCartOrdergetcart () const
 If unsuccessful: the cart with annotations. More...
 
Q_SLOT Nullable< MOOrdergetorder () const
 If successful: the created order. More...
 
MTCreateReservationoperator= (const MTCreateReservation &)
 copy assignment: the copy shares the state of the original object More...
 

Static Public Member Functions

static MTCreateReservation asyncQuery (const MOCartOrder &acart, 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 MTCreateReservation query (const MOCartOrder &acart, 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

 MTCreateReservation (const MOCartOrder &acart, 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 MTCreateReservation_Private
 

Detailed Description

Reservations are orders that are not executed right away. They may only contain tickets that block some seats for a limited time. They cannot contain any shopping items or vouchers.

Constructor & Destructor Documentation

MTCreateReservation::MTCreateReservation ( const MOCartOrder acart,
QString  iface 
)
explicitprotected

generates an instance from its properties

Parameters
acartThe cart contents
ifaceID of the interface that the transaction will be sent on

References MTCreateReservation_Private::in_cart, and MTCreateReservation_Private.

MTCreateReservation::MTCreateReservation ( )

default constructor: generates an invalid transaction

References MTCreateReservation_Private.

MTCreateReservation::MTCreateReservation ( const MTCreateReservation t)

copy constructor: the two copies share their state

References MTCreateReservation_Private::attach().

MTCreateReservation::~MTCreateReservation ( )
virtual

deletes this instance

References MTCreateReservation_Private::detach().

Member Function Documentation

MTCreateReservation MTCreateReservation::asyncQuery ( const MOCartOrder acart,
QString  iface = "MagicSmoke" 
)
static

emits the query over the network and returns the transaction object, use isFinished() to check for the transaction's state

Parameters
acartThe cart contents
ifaceID of the interface that the transaction will be sent on
void MTCreateReservation::endQuery ( )
protectedvirtual
Nullable< MOCartOrder > MTCreateReservation::getcart ( ) const

If unsuccessful: the cart with annotations.

References MTCreateReservation_Private::out_cart.

Nullable< MOOrder > MTCreateReservation::getorder ( ) const

If successful: the created order.

References MTCreateReservation_Private::out_order.

MTCreateReservation & MTCreateReservation::operator= ( const MTCreateReservation t)

copy assignment: the copy shares the state of the original object

References MTCreateReservation_Private::attach(), and MTCreateReservation_Private::detach().

MTCreateReservation MTCreateReservation::query ( const MOCartOrder acart,
QString  iface = "MagicSmoke" 
)
static

emits the query over the network and returns the finished transaction object

Parameters
acartThe cart contents
ifaceID of the interface that the transaction will be sent on

Referenced by MInterface::queryCreateReservation().

Friends And Related Function Documentation

friend class MTCreateReservation_Private
friend

Referenced by MTCreateReservation().


The documentation for this class was generated from the following files: