iopc::ArcCacheBase Class Reference
[iopclib-cache]

#include <arcCacheBase.h>

Inheritance diagram for iopc::ArcCacheBase:

Inheritance graph
[legend]

List of all members.

Public Member Functions

 ArcCacheBase (long minValue=MINLONG, long maxCost=MAXLONG, const Strategy &strat=Strategy::defaultStrategy)
 ArcCacheBase (long minValue, long maxCost, StrategySelector *stratSel)

Protected Member Functions

virtual ArcCacheItemaddLock (ArcCacheItem &item, bool rdonly)=0
virtual void rmLock (ArcCacheItem &item)=0


Detailed Description

Common predecessor of extended object caches using ARC replacement policy, they use ArcCacheItem to represent stored objects

Constructor & Destructor Documentation

iopc::ArcCacheBase::ArcCacheBase ( long  minValue = MINLONG,
long  maxCost = MAXLONG,
const Strategy strat = Strategy::defaultStrategy 
) [inline]

Initialize cache with the same strategies for all object.

Parameters:
minValue Minimal value of objects obliged to stay in the cache.
maxCost Maximal total cost of stored objects.
strat Default strategy.

iopc::ArcCacheBase::ArcCacheBase ( long  minValue,
long  maxCost,
StrategySelector stratSel 
) [inline]

Initialize cache with strategies passed by selector.

Parameters:
minValue Minimal value of objects obliged to stay in the cache.
maxCost Maximal total cost of stored objects.
strat strategy selector.


Member Function Documentation

virtual ArcCacheItem& iopc::ArcCacheBase::addLock ( ArcCacheItem item,
bool  rdonly 
) [protected, pure virtual]

Adds a lock to an item containing an object

Parameters:
item The item the lock should be added to.
rdonly Type of the lock.
Returns:
An item representing new lock (it's the same as the passed one)

Implemented in iopc::ArcCache< MapType >, and iopc::ArcCacheST< MapType >.

virtual void iopc::ArcCacheBase::rmLock ( ArcCacheItem item  )  [protected, pure virtual]

Removes one lock of an item representing an object

Parameters:
item The item the lock should be removed from.

Implemented in iopc::ArcCache< MapType >, and iopc::ArcCacheST< MapType >.


The documentation for this class was generated from the following file:

Generated on Tue Apr 14 16:46:42 2009 for IOPC 2 by  doxygen 1.5.6