LRUCache Struct Reference

Public interface of class 'LRUCache'. More...

#include <LRUCache.h>

Related Functions

(Note that these are not member functions.)



void LRUCache_clear (LRUCache_ptr self)
 Clears all entries in the cache.
LRUCache_ptr LRUCache_create (size_t threshold, LRU_CACHE_EQ_FUN key_eq_fun, LRU_CACHE_HASH_FUN key_hash_fun, LRU_CACHE_FREE_FUN free_entry_fun, void *custom_arg)
 The LRUCache class constructor.
void LRUCache_destroy (LRUCache_ptr self)
 The LRUCache class destructor.
boolean LRUCache_insert (LRUCache_ptr self, const void *key, const void *value)
 Inserts an element in the LRUCache.
void LRUCache_iter_values (const LRUCache_ptr self, const LRUCacheIter iter, void **k, void **v)
 Retrieves the key and value entries associated with the given iterator.
void * LRUCache_lookup (LRUCache_ptr self, const void *key)
 Looks up for an element in the LRUCache.
boolean LRUCache_remove (LRUCache_ptr self, const void *key)
 Removes the entry added with key "key" from the LRUCache.

Detailed Description

Public interface of class 'LRUCache'.

Author:
Alessandro Mariotti
Todo:
: Missing description

Definition of the public accessor for class LRUCache


Friends And Related Function Documentation

void LRUCache_clear ( LRUCache_ptr  self  )  [related]

Clears all entries in the cache.

Clears all entries in the cache

LRUCache_ptr LRUCache_create ( size_t  threshold,
LRU_CACHE_EQ_FUN  key_eq_fun,
LRU_CACHE_HASH_FUN  key_hash_fun,
LRU_CACHE_FREE_FUN  free_entry_fun,
void *  custom_arg 
) [related]

The LRUCache class constructor.

AutomaticStart

The LRUCache class constructor.

OAHash class keys equality and hashing functions can be used, e.g. OAHash_pointer_eq_fun and OAHash_pointer_hash_fun, respectively.

Parameters:
free_entry_fun can be NULL
custom_arg can be NULL
See also:
LRUCache_destroy, OAHash_create
void LRUCache_destroy ( LRUCache_ptr  self  )  [related]

The LRUCache class destructor.

The LRUCache class destructor

See also:
LRUCache_create
boolean LRUCache_insert ( LRUCache_ptr  self,
const void *  key,
const void *  value 
) [related]

Inserts an element in the LRUCache.

Inserts an element in the LRUCache

See also:
LRUCache_lookup
void LRUCache_iter_values ( const LRUCache_ptr  self,
const LRUCacheIter  iter,
void **  k,
void **  v 
) [related]

Retrieves the key and value entries associated with the given iterator.

Retrieves the key and value entries associated with the given iterator. Both key and value can be NULL

void * LRUCache_lookup ( LRUCache_ptr  self,
const void *  key 
) [related]

Looks up for an element in the LRUCache.

Looks up for an element in the LRUCache

See also:
LRUCache_insert
boolean LRUCache_remove ( LRUCache_ptr  self,
const void *  key 
) [related]

Removes the entry added with key "key" from the LRUCache.

Removes the entry added with key "key" from the LRUCache. Returns true if the key has been actually removed (i.e. the key was in the hash


The documentation for this struct was generated from the following file:
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines

Generated on 14 Oct 2015 for NuSMV Developers Manual by  doxygen 1.6.1