Skip to main content
ATL Server Library Reference 
CDllCache Class 

This class implements a DLL cache.

template <
   class MonitorClass,
   class Peer = CNoDllCachePeer
class CDllCache :
   public IDllCache,
   public IWorkerThreadClient



A worker thread class used for performing periodic cache maintenance. Typically, this will be CWorkerThread, but CNoWorkerthread can be used to disable cache maintenance.


A class conforming to the DLL cache peer archetype that contains data specific to each cached DLL. If the default CNoDllCachePeer is used, the cache will not contain DLL peer data.

CDllCache caches DLLs and implements IDllCache. The cache manages the loading and unloading of each DLL and uses reference counting to ensure that DLLs are not unloaded prematurely. With the help of MonitorClass, periodic cache maintenance is performed when Flush is called to remove stale entries from the cache, and flush items if the cache has reached the limited set through the IMemoryCacheControl interface. The frequency with which Flush is called is determined by the timeout value passed to Initialize.

Header: atlcache.h