\r\n

51Degrees Pipeline Node.js  4.3

51Degrees Pipeline for Node.js

LRUcache Class Reference

Detailed Description

An instance of DataKeyed cache using a least recently used (LRU) method.

Inheritance diagram for LRUcache:

[legend]

Collaboration diagram for LRUcache:

[legend]

Public Member Functions

 constructor ({ size=100 })
Constructor for LRUcache. More...
 get (cacheKey)
 put (cacheKey, value)

Public Member Functions inherited from DataKeyedCache

 get (cachekey)
Get data out of the cache. More...
 put (cachekey, value)
Add an element to the cache. More...

Member Function Documentation

◆ constructor()

LRUcache::constructor (   { size=100 } )
inline

Constructor for LRUcache.

Parameters
{object} - options options for the lru cache
{number} - options.size maximum entries in the cache