|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.openjpa.datacache.CacheStatisticsImpl
public class CacheStatisticsImpl
The default CacheStatistics(SPI) implementation.
| Constructor Summary | |
|---|---|
CacheStatisticsImpl()
|
|
| Method Summary | |
|---|---|
Set<String> |
classNames()
Returns the types that are known to this cache being tracked. |
void |
disable()
Disable statistics collection. |
void |
enable()
SPI implementation |
long |
getHitCount()
Gets number of total read requests that has been found in cache since last reset. |
long |
getHitCount(Class<?> c)
Gets number of total read requests that has been found in cache for the given class since last reset. |
long |
getHitCount(String str)
Gets number of total read requests that has been found in cache for the given class since last reset. |
long |
getReadCount()
Gets number of total read requests since last reset. |
long |
getReadCount(Class<?> c)
Gets number of total read requests for the given class since last reset. |
long |
getReadCount(String str)
Gets number of total read requests for the given class since last reset. |
long |
getTotalHitCount()
Gets number of total read requests that has been found in cache since start. |
long |
getTotalHitCount(Class<?> c)
Gets number of total read requests that has been found in cache for the given class since start. |
long |
getTotalHitCount(String str)
Gets number of total read requests that has been found in cache for the given class since start. |
long |
getTotalReadCount()
Gets number of total read requests since start. |
long |
getTotalReadCount(Class<?> c)
Gets number of total read requests for the given class since start. |
long |
getTotalReadCount(String str)
Gets number of total read requests for the given class since start. |
long |
getTotalWriteCount()
Gets number of total write requests since start. |
long |
getTotalWriteCount(Class<?> c)
Gets number of total write requests for the given class since start. |
long |
getTotalWriteCount(String str)
Gets number of total write requests for the given class since start. |
long |
getWriteCount()
Gets number of total write requests since last reset. |
long |
getWriteCount(Class<?> c)
Gets number of total write requests for the given class since last reset. |
long |
getWriteCount(String str)
Gets number of total write requests for the given class since last reset. |
boolean |
isEnabled()
Returns whether or not statistics will be collected. |
void |
newGet(Class<?> cls,
boolean hit)
Record a new cache get. |
void |
newGet(Object oid,
boolean hit)
|
void |
newPut(Class<?> cls)
Record a new cache put. |
void |
newPut(Object oid)
|
void |
reset()
Clears all accumulated statistics. |
Date |
since()
Gets the time of last reset. |
Date |
start()
Gets the time of start. |
Map<String,long[]> |
toMap()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CacheStatisticsImpl()
| Method Detail |
|---|
public long getReadCount()
CacheStatistics
getReadCount in interface CacheStatisticspublic long getHitCount()
CacheStatistics
getHitCount in interface CacheStatisticspublic long getWriteCount()
CacheStatistics
getWriteCount in interface CacheStatisticspublic long getTotalReadCount()
CacheStatistics
getTotalReadCount in interface CacheStatisticspublic long getTotalHitCount()
CacheStatistics
getTotalHitCount in interface CacheStatisticspublic long getTotalWriteCount()
CacheStatistics
getTotalWriteCount in interface CacheStatisticspublic long getReadCount(Class<?> c)
CacheStatistics
getReadCount in interface CacheStatisticspublic long getReadCount(String str)
CacheStatistics
getReadCount in interface CacheStatisticspublic long getHitCount(Class<?> c)
CacheStatistics
getHitCount in interface CacheStatisticspublic long getHitCount(String str)
CacheStatistics
getHitCount in interface CacheStatisticspublic long getWriteCount(Class<?> c)
CacheStatistics
getWriteCount in interface CacheStatisticspublic long getWriteCount(String str)
CacheStatistics
getWriteCount in interface CacheStatisticspublic long getTotalReadCount(Class<?> c)
CacheStatistics
getTotalReadCount in interface CacheStatisticspublic long getTotalReadCount(String str)
CacheStatistics
getTotalReadCount in interface CacheStatisticspublic long getTotalHitCount(Class<?> c)
CacheStatistics
getTotalHitCount in interface CacheStatisticspublic long getTotalHitCount(String str)
CacheStatistics
getTotalHitCount in interface CacheStatisticspublic long getTotalWriteCount(Class<?> c)
CacheStatistics
getTotalWriteCount in interface CacheStatisticspublic long getTotalWriteCount(String str)
CacheStatistics
getTotalWriteCount in interface CacheStatisticspublic Date since()
CacheStatistics
since in interface CacheStatisticspublic Date start()
CacheStatistics
start in interface CacheStatisticspublic void reset()
CacheStatistics
reset in interface CacheStatisticspublic boolean isEnabled()
CacheStatistics
isEnabled in interface CacheStatisticspublic Set<String> classNames()
CacheStatistics
classNames in interface CacheStatisticspublic Map<String,long[]> toMap()
toMap in interface CacheStatisticspublic void enable()
enable in interface CacheStatisticsSPIpublic void disable()
CacheStatisticsSPI
disable in interface CacheStatisticsSPI
public void newGet(Class<?> cls,
boolean hit)
CacheStatisticsSPI
newGet in interface CacheStatisticsSPIcls - - The class describing the type that is contained in the cache.hit - - true for a cache hit, false otherwise
public void newGet(Object oid,
boolean hit)
public void newPut(Class<?> cls)
CacheStatisticsSPI
newPut in interface CacheStatisticsSPIcls - - The class describing the type that is contained in the cache.public void newPut(Object oid)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||