public class JavaxCacheQueryCompilationCache extends Object implements QueryCompilationCache, Serializable
Constructor and Description |
---|
JavaxCacheQueryCompilationCache(NucleusContext nucleusCtx) |
Modifier and Type | Method and Description |
---|---|
void |
clear()
Method to clear the cache.
|
void |
close()
Method to close the cache when no longer needed.
|
boolean |
contains(String queryKey)
Accessor for whether the specified query is in the cache
|
void |
evict(String queryKey)
Evict the query from the compilation cache.
|
QueryCompilation |
get(String queryKey)
Accessor for a (generic) compilation from the cache.
|
boolean |
isEmpty()
Accessor for whether the cache is empty.
|
QueryCompilation |
put(String queryKey,
QueryCompilation compilation)
Method to put an object in the cache.
|
int |
size()
Accessor for the total number of compilations in the query cache.
|
public JavaxCacheQueryCompilationCache(NucleusContext nucleusCtx)
public void close()
QueryCompilationCache
close
in interface QueryCompilationCache
public void evict(String queryKey)
QueryCompilationCache
evict
in interface QueryCompilationCache
queryKey
- Key for the query to evict.public void clear()
QueryCompilationCache
clear
in interface QueryCompilationCache
public boolean isEmpty()
QueryCompilationCache
isEmpty
in interface QueryCompilationCache
public int size()
QueryCompilationCache
size
in interface QueryCompilationCache
public QueryCompilation get(String queryKey)
QueryCompilationCache
get
in interface QueryCompilationCache
queryKey
- The query keypublic QueryCompilation put(String queryKey, QueryCompilation compilation)
QueryCompilationCache
put
in interface QueryCompilationCache
queryKey
- The query keycompilation
- The compilation to cachepublic boolean contains(String queryKey)
QueryCompilationCache
contains
in interface QueryCompilationCache
queryKey
- The query keyCopyright © 2019. All rights reserved.