MagicSmoke
$VERSION$
|
This class represents a coupon. More...
#include <srcMOCoupon.h>
Public Member Functions | |
MOCoupon () | |
default constructor: constructs an invalid instance of MOCoupon More... | |
MOCoupon (const MOCoupon &) | |
copy constructor: creates a (deep) copy of the object More... | |
MOCoupon (const QDomElement &) | |
special constructor: create from the XML representation, deserializing the object More... | |
virtual | ~MOCoupon () |
destructor: deletes this copy of the object More... | |
virtual void | addrules (Nullable< MOCouponRule > a) |
virtual Nullable< qint64 > | amountuse () const |
virtual void | clearrules () |
virtual Nullable< QString > | couponid () const |
virtual Nullable< QString > | description () const |
virtual Nullable< QString > | flags () const |
MOCoupon & | operator= (const MOCoupon &) |
copy assignment: creates a (deep) copy of the object More... | |
virtual QList< MOCouponRule > | rules () const |
virtual void | setamountuse (Nullable< qint64 > s) |
virtual void | setcouponid (Nullable< QString > s) |
virtual void | setdescription (Nullable< QString > s) |
virtual void | setflags (Nullable< QString > s) |
virtual void | setrules (QList< MOCouponRule > s) |
virtual void | setticketsperorder (Nullable< qint64 > s) |
virtual void | setvalidfrom (Nullable< qint64 > s) |
virtual void | setvalidtill (Nullable< qint64 > s) |
virtual Nullable< qint64 > | ticketsperorder () const |
QString | toString () |
Serializes the object to XML and returns the string representation of that XML. More... | |
QDomElement | toXml (QDomDocument &doc, QString name="Coupon") |
Transforms the object into its XML representation, the element node returned is not appended to the document - you have to do that yourself. More... | |
void | toXml (QDomDocument &, QDomElement &) |
Serializes the object into the given element. More... | |
virtual Nullable< qint64 > | validfrom () const |
virtual Nullable< qint64 > | validtill () const |
Static Public Member Functions | |
static MOCoupon | fromString (const QString &) |
create MOCoupon from XML formatted string (inverse of toString) More... | |
static MOCoupon | fromXml (const QDomElement &) |
create MOCoupon from XML (inverse of toXml) More... | |
Protected Attributes | |
Nullable< qint64 > | mp_amountuse |
Nullable< QString > | mp_couponid |
Nullable< QString > | mp_description |
Nullable< QString > | mp_flags |
QList< MOCouponRule > | mp_rules |
Nullable< qint64 > | mp_ticketsperorder |
Nullable< qint64 > | mp_validfrom |
Nullable< qint64 > | mp_validtill |
This class represents a coupon.
|
inline |
default constructor: constructs an invalid instance of MOCoupon
Referenced by fromString(), and fromXml().
MOCoupon::MOCoupon | ( | const MOCoupon & | o | ) |
copy constructor: creates a (deep) copy of the object
References mp_amountuse, mp_couponid, mp_description, mp_flags, mp_rules, mp_ticketsperorder, mp_validfrom, and mp_validtill.
|
explicit |
special constructor: create from the XML representation, deserializing the object
References addrules(), setamountuse(), setcouponid(), setdescription(), setflags(), setticketsperorder(), setvalidfrom(), and setvalidtill().
|
inlinevirtual |
destructor: deletes this copy of the object
|
inlinevirtual |
Referenced by MOCoupon().
|
inlinevirtual |
|
inlinevirtual |
|
inlinevirtual |
|
inlinevirtual |
|
inlinevirtual |
|
static |
create MOCoupon from XML formatted string (inverse of toString)
References MOCoupon().
|
static |
create MOCoupon from XML (inverse of toXml)
References MOCoupon().
copy assignment: creates a (deep) copy of the object
References mp_amountuse, mp_couponid, mp_description, mp_flags, mp_rules, mp_ticketsperorder, mp_validfrom, and mp_validtill.
|
inlinevirtual |
|
inlinevirtual |
Referenced by MOCoupon().
|
inlinevirtual |
Referenced by MOCoupon().
|
inlinevirtual |
Referenced by MOCoupon().
|
inlinevirtual |
Referenced by MOCoupon().
|
inlinevirtual |
|
inlinevirtual |
Referenced by MOCoupon().
|
inlinevirtual |
Referenced by MOCoupon().
|
inlinevirtual |
Referenced by MOCoupon().
|
inlinevirtual |
QString MOCoupon::toString | ( | ) |
Serializes the object to XML and returns the string representation of that XML.
References toXml().
QDomElement MOCoupon::toXml | ( | QDomDocument & | doc, |
QString | name = "Coupon" |
||
) |
Transforms the object into its XML representation, the element node returned is not appended to the document - you have to do that yourself.
doc | the DOM document node for which to generate the element |
name | the name to give the generated element, per default "MOCoupon" is used |
Referenced by toString(), and toXml().
void MOCoupon::toXml | ( | QDomDocument & | doc, |
QDomElement & | r | ||
) |
Serializes the object into the given element.
References mp_amountuse, mp_couponid, mp_description, mp_flags, mp_rules, mp_ticketsperorder, mp_validfrom, mp_validtill, and toXml().
|
inlinevirtual |
|
inlinevirtual |
|
protected |
Referenced by MOCoupon(), operator=(), and toXml().
|
protected |
Referenced by MOCoupon(), operator=(), and toXml().
|
protected |
Referenced by MOCoupon(), operator=(), and toXml().
|
protected |
Referenced by MOCoupon(), operator=(), and toXml().
|
protected |
Referenced by MOCoupon(), operator=(), and toXml().
|
protected |
Referenced by MOCoupon(), operator=(), and toXml().
|
protected |
Referenced by MOCoupon(), operator=(), and toXml().
|
protected |
Referenced by MOCoupon(), operator=(), and toXml().