This class implements a test utility that gives the test driver access to the lock / unlock method of the RW mutex. Its purpose is to allow testing that the locking actually happens as planned.

Synopsis

Declared in <bdlcc_cache.h>

template<
    class KEY,
    class VALUE,
    class HASH = bsl::hash<KEY>,
    class EQUAL = bsl::equal_to<KEY>>
class Cache_TestUtil;

Member Functions

Name

Description

Cache_TestUtil [constructor]

Create a Cache_TestUtil object to test locking in the specified cache.

lockRead

Call the lockRead method of bdlcc::Cache d_rwlock lock.

lockWrite

Call the lockWrite method of bdlcc::Cache d_rwlock lock.

unlock

Call the unlock method of bdlcc::Cache d_rwlock lock.

Created with MrDocs