|
Kodo 4.1.0 generated on October 9 2006 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.openjpa.datacache.DelegatingQueryCache
kodo.datacache.MonitoringQueryCache
public class MonitoringQueryCache
Delegating query cache that provides monitoring statistics.
| Constructor Summary | |
|---|---|
MonitoringQueryCache(org.apache.openjpa.conf.OpenJPAConfiguration conf,
org.apache.openjpa.datacache.QueryCache cache)
Provide delegate on construction. |
|
| Method Summary | |
|---|---|
void |
close()
|
org.apache.openjpa.datacache.QueryResult |
get(org.apache.openjpa.datacache.QueryKey key)
|
double |
getHitRate()
Returns the percentage of hits. |
int |
getHits()
Returns the number of cache hits for invocations of the get(org.apache.openjpa.datacache.QueryKey)
method. |
int |
getMisses()
Returns the number of cache misses for invocations of the get(org.apache.openjpa.datacache.QueryKey)
method. |
Collection |
getStatistics()
Get statistics exported by this object. |
String |
getStatisticsString()
Returns a localized string containing the number of hits, the number of misses, and the hit ratio ( hits / (hits+misses)). |
void |
resetStatistics()
Reset the caching statistics. |
| Methods inherited from class org.apache.openjpa.datacache.DelegatingQueryCache |
|---|
addTypesChangedListener, clear, equals, getDelegate, getInnermostDelegate, hashCode, initialize, onTypesChanged, pin, put, remove, removeTypesChangedListener, translate, unpin, writeLock, writeUnlock |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MonitoringQueryCache(org.apache.openjpa.conf.OpenJPAConfiguration conf,
org.apache.openjpa.datacache.QueryCache cache)
| Method Detail |
|---|
public int getHits()
get(org.apache.openjpa.datacache.QueryKey)
method.
public int getMisses()
get(org.apache.openjpa.datacache.QueryKey)
method.
public double getHitRate()
public String getStatisticsString()
hits / (hits+misses)).
public Collection getStatistics()
getStatistics in interface StatisticsProviderpublic void resetStatistics()
public org.apache.openjpa.datacache.QueryResult get(org.apache.openjpa.datacache.QueryKey key)
get in interface org.apache.openjpa.datacache.QueryCacheget in class org.apache.openjpa.datacache.DelegatingQueryCachepublic void close()
close in interface org.apache.openjpa.datacache.QueryCacheclose in interface org.apache.openjpa.lib.util.Closeableclose in class org.apache.openjpa.datacache.DelegatingQueryCache
|
Kodo 4.1.0 generated on October 9 2006 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||