public class IsisCache extends Object
Created: 25 août 06 22:42:47
Last update: $Date: 2013-12-08 19:57:15 +0100 (Sun, 08 Dec 2013) $ by : $Author: bpoussin $
| Modifier and Type | Field and Description |
|---|---|
protected IsisCacheBackend |
cacheBackend |
protected long |
cacheUsed |
static IsisCacheBackend.Factory |
defaultFactory |
protected long |
totalCall |
| Constructor and Description |
|---|
IsisCache() |
IsisCache(IsisCacheBackend cacheBackend) |
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
remove all values in cache
|
void |
clear(TimeStep step)
remove all values in cache for the specied TimeStep
|
protected TimeStep |
computeKey(StringBuilder sbKey,
Method method,
Object[] args) |
Object |
get(Method method,
Object[] args,
Object defaultValue)
Recupere pour un pas de temps donnes une valeur calcule pour une cle
|
protected Object |
get(TimeStep step,
String key) |
long |
getCacheUsed() |
long |
getTotalCall() |
protected Trace |
getTrace()
Return trace object from context.
|
String |
printStatistiqueAndClear()
Affiche les statistiques
|
protected void |
put(TimeStep step,
String key,
Object value) |
protected Object |
realCall(Object defaultValue)
On fait l'appel reel dans une autre methode pour pouvoir le savoir dans
les traces
|
public static IsisCacheBackend.Factory defaultFactory
protected long totalCall
protected long cacheUsed
protected IsisCacheBackend cacheBackend
public IsisCache()
public IsisCache(IsisCacheBackend cacheBackend)
protected Trace getTrace()
public Object get(Method method, Object[] args, Object defaultValue) throws Throwable
step - le pas de temps pour lequel on souhaite ajouter (ou
null)key - la cle de storagedefaultValue - la valeur par defaut a retourner si elle n'est pas en
cache si defaultValue est une JoinPoint alors un
proceed est appele dessus et le resultat de l'appel
est utiliser comme valeur par defautThrowableprotected TimeStep computeKey(StringBuilder sbKey, Method method, Object[] args)
protected Object realCall(Object defaultValue) throws Throwable
jp - Throwablepublic void clear()
public void clear(TimeStep step)
public long getCacheUsed()
public long getTotalCall()
public String printStatistiqueAndClear()
Copyright © 1999–2013 CodeLutin. All rights reserved.