- CS
- Utility
- Implementation
- FixedSizeLRU
![]() |
Public API Reference |
LRU implemented as a fixed size array storing the indices in order of reference. More...
#include <csutil/fixedsizecache.h>
Public Member Functions | |
| FixedSizeLRU () | |
| Initialize the LRU array. | |
| size_t | GetVictim () const |
| Return last recently used item. | |
| void | Update (size_t index) |
| Set index as last accessed. | |
LRU implemented as a fixed size array storing the indices in order of reference.
Performs best for relatively small sizes.
| Size | LRU size |
Definition at line 406 of file fixedsizecache.h.
| CS::Utility::Implementation::FixedSizeLRU< Size >::FixedSizeLRU | ( | ) | [inline] |
Initialize the LRU array.
Definition at line 410 of file fixedsizecache.h.
| size_t CS::Utility::Implementation::FixedSizeLRU< Size >::GetVictim | ( | ) | const [inline] |
Return last recently used item.
Definition at line 436 of file fixedsizecache.h.
| void CS::Utility::Implementation::FixedSizeLRU< Size >::Update | ( | size_t | index | ) | [inline] |
Set index as last accessed.
Definition at line 419 of file fixedsizecache.h.