|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.netflix.servo.monitor.AbstractMonitor<java.lang.Number>
com.netflix.servo.monitor.ResettableCounter
public class ResettableCounter
Counter implementation that keeps track of updates since the last reset.
| Field Summary |
|---|
| Fields inherited from class com.netflix.servo.monitor.AbstractMonitor |
|---|
config |
| Constructor Summary | |
|---|---|
ResettableCounter(MonitorConfig config)
Create a new instance of the counter. |
|
ResettableCounter(MonitorConfig config,
long estPollingInterval)
Deprecated. Polling intervals are configured via the system wide property servo.pollers instead |
|
| Method Summary | |
|---|---|
boolean |
equals(java.lang.Object obj)
|
java.lang.Number |
getAndResetValue()
Return the value and reset the monitor state for the default polling interval. |
java.lang.Number |
getAndResetValue(int pollerIdx)
Return the value and reset the monitor state for a given polling interval. |
long |
getCount()
Returns the raw count instead of the rate. |
java.lang.Number |
getValue()
Returns the current value for the monitor. |
int |
hashCode()
|
void |
increment()
Update the count by one. |
void |
increment(long amount)
Update the count by the specified amount. |
java.lang.String |
toString()
|
| Methods inherited from class com.netflix.servo.monitor.AbstractMonitor |
|---|
getConfig |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface com.netflix.servo.monitor.Monitor |
|---|
getConfig |
| Constructor Detail |
|---|
public ResettableCounter(MonitorConfig config)
@Deprecated
public ResettableCounter(MonitorConfig config,
long estPollingInterval)
config - configuration for the monitorestPollingInterval - ignored| Method Detail |
|---|
public void increment()
increment in interface Counterpublic void increment(long amount)
increment in interface Counterpublic java.lang.Number getValue()
getValue in interface Monitor<java.lang.Number>public java.lang.Number getAndResetValue()
getAndResetValue in interface ResettableMonitor<java.lang.Number>public java.lang.Number getAndResetValue(int pollerIdx)
getAndResetValue in interface ResettableMonitor<java.lang.Number>public long getCount()
public boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||