Skip to content
  • hjk's avatar
    Utils: Add a ObjectPool convenience class template · f6715fe5
    hjk authored
    
    
    The ObjectPool class template provides parts of the functionality
    of the global PluginManager object pool but is intented to be
    used with smaller set objects, typically with same base type (e.g.
    factories) only.
    
    The ObjectPool takes ownership of add items if and only if the item does
    not have a QObject parent.
    
    Items owned by the Object pool are destructed when the pool is
    destructed, the other items are taken care of by their QObject parent
    according to the usual parent/child behavior.
    
    Change-Id: I60886095c8b04eae017e1fb56774b1bf66dbefa1
    Reviewed-by: default avatarTobias Hunger <tobias.hunger@qt.io>
    Reviewed-by: default avatarEike Ziller <eike.ziller@qt.io>
    f6715fe5