|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmessif.statistics.Statistics<StatisticSimpleWeakrefCounter>
messif.statistics.StatisticSimpleWeakrefCounter
public class StatisticSimpleWeakrefCounter
Field Summary | |
---|---|
protected java.util.Map<java.lang.Object,java.lang.Long> |
values
Reference counter data |
Fields inherited from class messif.statistics.Statistics |
---|
replaceWith |
Constructor Summary | |
---|---|
protected |
StatisticSimpleWeakrefCounter(java.lang.String name)
Creates a new instance of StatisticRefCounter |
Method Summary | |
---|---|
void |
add(java.lang.Object key)
|
void |
add(java.lang.Object key,
long value)
Adds the passed value to the current value associated with the passed key. |
protected StatisticSimpleWeakrefCounter |
cast()
Returns this statistics as the type provided typed argument. |
boolean |
containsKey(java.lang.Object key)
|
protected int |
deepHashCode()
|
long |
get(java.lang.Object key)
Reference counter read operations |
int |
getKeyCount()
|
java.util.Set<java.lang.Object> |
getKeys()
|
static StatisticSimpleWeakrefCounter |
getStatistics(java.lang.String name)
Create new statistic object with specified name or get the one already existing |
boolean |
changedSinceCheckpoint()
Reports if value of refCounter has been changed since the last setCheckpoint() call. |
boolean |
remove(java.lang.Object key,
boolean propagateDelete)
Return either the StatisticCounter for given key and remove it from the mapping or return null, if the key is not in the map |
void |
reset()
Reset the current statistic (this one only). |
void |
set(java.lang.Object key,
long value)
Reference counter modification operations |
protected void |
setFrom(StatisticSimpleWeakrefCounter sourceStat)
Set the value of this statistic to the actual value of the given sourceStat . |
void |
setCheckpoint()
Sets checkpoint. |
void |
sub(java.lang.Object key)
|
void |
sub(java.lang.Object key,
long value)
|
java.lang.String |
toString()
Text representation |
protected void |
updateFrom(StatisticSimpleWeakrefCounter sourceStat)
Statistics merging |
Methods inherited from class messif.statistics.Statistics |
---|
addBoundStat, bindTo, canPerformOperation, disableGlobally, enableGlobally, getAllStatistics, getAllStatistics, getBoundStats, getBoundTo, getName, getStatistics, isBound, isEnabledGlobally, isRegisteredGlobally, printStatistics, printStatistics, printStatistics, readResolve, removeBoundStat, removeStatistic, resetStatistics, resetStatistics, unbind |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected transient java.util.Map<java.lang.Object,java.lang.Long> values
Constructor Detail |
---|
protected StatisticSimpleWeakrefCounter(java.lang.String name)
Method Detail |
---|
public long get(java.lang.Object key)
public java.util.Set<java.lang.Object> getKeys()
public int getKeyCount()
public boolean containsKey(java.lang.Object key)
public void set(java.lang.Object key, long value)
public boolean remove(java.lang.Object key, boolean propagateDelete)
public void add(java.lang.Object key, long value)
public void add(java.lang.Object key)
public void sub(java.lang.Object key, long value)
public void sub(java.lang.Object key)
protected void updateFrom(StatisticSimpleWeakrefCounter sourceStat)
updateFrom
in class Statistics<StatisticSimpleWeakrefCounter>
sourceStat
- the statistic from which to update this statprotected void setFrom(StatisticSimpleWeakrefCounter sourceStat)
Statistics
sourceStat
.
setFrom
in class Statistics<StatisticSimpleWeakrefCounter>
sourceStat
- the statistic from which to set this statpublic void reset()
reset
in class Statistics<StatisticSimpleWeakrefCounter>
public static StatisticSimpleWeakrefCounter getStatistics(java.lang.String name) throws java.lang.ClassCastException
java.lang.ClassCastException
public java.lang.String toString()
toString
in class java.lang.Object
protected int deepHashCode()
public boolean changedSinceCheckpoint()
public void setCheckpoint()
protected StatisticSimpleWeakrefCounter cast()
Statistics
cast
in class Statistics<StatisticSimpleWeakrefCounter>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |