|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||
java.lang.Objectde.mid.innovator.net.InoTelegramCache<T>
public class InoTelegramCache<T extends InoTelegram>
A cache that manages entries based on the policy specified at creation time. The initial size of the cache can be configured through the "de.mid.innovator.api.cache.size" system property. The default size is 2048 entries.
| Nested Class Summary | |
|---|---|
static class |
InoTelegramCache.CachePolicy
|
| Constructor Summary | |
|---|---|
InoTelegramCache()
Creates a cache with specific policy |
|
| Method Summary | |
|---|---|
void |
clear()
|
void |
disable()
|
T |
get(T key)
Queries the cache for the specific host. |
int |
getAccessCnt()
|
int |
getHitCnt()
|
InoTelegramCache<T> |
put(T send,
T rcv)
Adds an entry to the cache. |
void |
resetStatistics()
|
void |
setPolicy(InoTelegramCache.CachePolicy policy)
Change the cache policy and use this policy for the future use of the cache. |
int |
size()
|
String |
stats()
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public InoTelegramCache()
| Method Detail |
|---|
public void clear()
public void disable()
public T get(T key)
public int getAccessCnt()
public int getHitCnt()
public InoTelegramCache<T> put(T send,
T rcv)
public void resetStatistics()
public void setPolicy(InoTelegramCache.CachePolicy policy)
policy - New policy to use for cache.public int size()
public String stats()
public String toString()
toString in class Object
|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||