|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sonyericsson.jenkins.plugins.bfa.graphs.GraphCache
public final class GraphCache
A class for caching Graph
-objects. Maps a string-key to each Graph
-object.
Method Summary | |
---|---|
hudson.util.Graph |
get(String key,
Callable<hudson.util.Graph> callable)
Get the Graph corresponding to the specified key. |
static int |
getExpirationTime()
Gets the expiration time for cached objects. |
static GraphCache |
getInstance()
Get the singleton-instance. |
List<String> |
getMatchingCacheKeys(Pattern pattern)
Gets all matching graph cache ids/keys. |
void |
invalidate(String key)
Invalidate the object with the specified key. |
void |
invalidateMatching(Pattern pattern)
Invalidates all graphs matching argument pattern. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static GraphCache getInstance()
GraphCache
-instancepublic void invalidate(String key)
key
- The key whose Graph to invalidatepublic void invalidateMatching(Pattern pattern)
pattern
- the pattern to match for graph idspublic List<String> getMatchingCacheKeys(Pattern pattern)
pattern
- the pattern to match for graph ids
public static int getExpirationTime()
public hudson.util.Graph get(String key, Callable<hudson.util.Graph> callable) throws ExecutionException
key
- The key for the graphcallable
- A callback to construct the graph that wasn't cached
ExecutionException
- If a graph e.g. cannot be generated
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |