diff options
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/managed/ManagedContainer.hpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/core/managed/ManagedContainer.hpp b/src/core/managed/ManagedContainer.hpp index 6bf1915..f58cb59 100644 --- a/src/core/managed/ManagedContainer.hpp +++ b/src/core/managed/ManagedContainer.hpp @@ -28,6 +28,7 @@ #define _OUSIA_MANAGED_CONTAINER_H_ #include <iostream> +#include <initializer_list> #include <unordered_map> #include <unordered_set> #include <vector> @@ -189,6 +190,18 @@ protected: public: /** + * Constructor of the ManagedContainer class with no owner (will contain + * rooted entries). + */ + ManagedContainer() : owner(nullptr) {}; + + /** + * Constructor of the ManagedContainer class with an initializer list but + * no owner (will contain rooted entries). + */ + ManagedContainer(std::initializer_list<T> l) : owner(nullptr), c(l) {}; + + /** * Constructor of the ManagedContainer class. * * @param owner is the managed object which owns the collection and all |