cache_t Struct Reference

Definition of the structure to keep track of the internal details of the cache allocator. More...

#include <cache.h>

List of all members.

Public Attributes

pthread_mutex_t mutex
 Mutex to protect access to the structure.
char * name
 Name of the cache objects in this cache (provided by the caller).
void ** ptr
 List of pointers to available buffers in this cache.
size_t bufsize
 The size of each element in this cache.
int freetotal
 The capacity of the list of elements.
int freecurr
 The current number of free elements.
cache_constructor_tconstructor
 The constructor to be called each time we allocate more memory.
cache_destructor_tdestructor
 The destructor to be called each time before we release memory.


Detailed Description

Definition of the structure to keep track of the internal details of the cache allocator.

Touching any of these variables results in undefined behavior.


Member Data Documentation

The size of each element in this cache.

The constructor to be called each time we allocate more memory.

The destructor to be called each time before we release memory.

The current number of free elements.

The capacity of the list of elements.

pthread_mutex_t cache_t::mutex

Mutex to protect access to the structure.

Name of the cache objects in this cache (provided by the caller).

void** cache_t::ptr

List of pointers to available buffers in this cache.


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

Generated on Fri Apr 17 16:28:30 2009 for memcached by  doxygen 1.5.8