diff options
author | Stijn Buys <ingar@osirion.org> | 2012-03-07 20:35:50 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2012-03-07 20:35:50 +0000 |
commit | c5f45c9d2cef13974c08773cd0f788de12ee2ce4 (patch) | |
tree | 4b5013f99aa3a2d7ce8e97cfffe18edc4b23e438 /src/properties.h | |
parent | 802fe3321306a81e227584e34087b477110ffdb5 (diff) |
Added Properties copy constructor and assignment operator.
Diffstat (limited to 'src/properties.h')
-rw-r--r-- | src/properties.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/properties.h b/src/properties.h index efde85b..89c9c93 100644 --- a/src/properties.h +++ b/src/properties.h @@ -26,6 +26,11 @@ class Properties public: Properties(); + /** + * @brief copy constructor + * */ + Properties(const Properties & other); + virtual ~Properties(); /* ---- inspectors ---- */ @@ -89,6 +94,19 @@ public: /* ---- mutators ---- */ /** + * @brief assign all values of another Properties instance to this instance + * */ + void assign(const Properties & other); + + /** + * @brief assignment operator + * */ + inline Properties & operator=(const Properties & other) { + assign(other); + return *this; + } + + /** * @brief set the comments string of this object * */ inline void set_comment(const QString &text) { |