From c5d18a42da8e9ed19c9520308fef087f4fb76323 Mon Sep 17 00:00:00 2001 From: Andreas Stöckel Date: Sun, 14 Dec 2014 02:03:52 +0100 Subject: added data functions and memory tagging functions. As it turns out the latter are unnecessary and will be removed --- src/core/managed/ManagedContainer.hpp | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'src/core/managed/ManagedContainer.hpp') diff --git a/src/core/managed/ManagedContainer.hpp b/src/core/managed/ManagedContainer.hpp index 9ff75d5..7b18bcd 100644 --- a/src/core/managed/ManagedContainer.hpp +++ b/src/core/managed/ManagedContainer.hpp @@ -31,8 +31,8 @@ namespace ousia { /** - * Template class which can be used to collect "Owned" refrences to a certain - * type of managed object. Do not use this class directly, use ManagedMap or + * Template class which can be used to collect refrences to a certain type of + * managed objects. Do not use this class directly, use ManagedMap or * ManagedVector instead. This class only provides functionality which is common * to list and map containers (iterators and state). * @@ -40,7 +40,7 @@ namespace ousia { * @param Collection should be a STL container of Owned */ template -class ManagedContainer { +class ManagedContainer : Managed { public: using collection_type = Collection; using value_type = typename collection_type::value_type; @@ -81,7 +81,12 @@ public: * @param owner is the managed object which owns the collection and all * handles to other managed objects stored within. */ - ManagedContainer(Handle owner) : owner(owner){}; + ManagedContainer(Handle owner) : Managed(owner->getManager), owner(owner){}; + + /** + * Destructor of the ManagedContainer class. + */ + virtual ~ManagedContainer() {}; /* State functions */ size_type size() const noexcept { return c.size(); } -- cgit v1.2.3