Class: modelit.mapviewer.MemoryCache

Extends: modelit.mapviewer.Cache & matlab.mixin.SetGet & handle

DESCRIPTION:

Cache to store items retrieved with the modelit.concurrent.ThreadPoolExecutor.

Properties

No properties

Public Method: MemoryCache

DESCRIPTION:

MemoryCache constructor.

CALL:

obj = MemoryCache() Documentation for modelit.mapviewer.MemoryCache/MemoryCache doc modelit.mapviewer.MemoryCache

Public Method: add

DESCRIPTION:

Add an item to the Cache.

CALL:

add(obj, item)

Public Method: purge

DESCRIPTION:

Remove all expired items from the Cache and limit the total items to the maxItems.

CALL:

purge(obj)

Public Method: get

DESCRIPTION:

Get an item from the Cache by using its key.

CALL:

item = get(obj, key)

Public Method: clear

DESCRIPTION:

Clear all the items in the Cache.

CALL:

item = getCacheItem(obj, key)

INPUT:

obj any
<modelit.mapviewer.MemoryCache>

Public Method: remove

DESCRIPTION:

Remove an item with the specified key from the Cache.

CALL:

remove(obj, key)

Private Method: findInCache

DESCRIPTION:

Get the index of an item in the Cache by using its key.

CALL:

remove(obj, key)