Multi Cache Module
Basic Stuff

This file contains the definition of a GWEN_MULTICACHE, a cache for multiple types of data.

This file contains the definition of a GWEN_MULTICACHE, a cache for multiple types of data.

The idea behind this is to make it easier to handle multiple types of objects by a single central cache object. You only set the maximum total size the central cache object is allowed to provide and that object will use this sum of memory to provide a caching mechanism for multiple different types.

You'll have to create a single central cache object (GWEN_MULTICACHE). Then you can create a GWEN_MULTICACHE_TYPE object for each kind of data you want to have managed. For the GWEN_MULTICACHE_TYPE object you need to provide functions which will increase and decrease the reference counter of the object cached.