11 #include <framework/pcore/Mergeable.h>
57 auto* otherMergeable =
static_cast<const MapMergeable*
>(other);
58 for (
const auto& element : otherMergeable->get()) {
61 it->second += element.second;
Wrap an STL map to make it mergeable.
ClassDef(MapMergeable, 1)
Wrap an STL map to make it mergeable.
const T & get() const
Get the wrapped standard object.
MapMergeable(Args &&... params)
Constructor, forwards all arguments to T constructor.
T & get()
Get the wrapped standard object.
T m_wrapped
Wrapped object.
virtual void merge(const Mergeable *other)
Merge object 'other' into this one.
virtual void clear()
Clear content of this object (e.g.
Abstract base class for objects that can be merged.
Abstract base class for different kinds of events.