SampledCounter
| Modifier and Type | Field and Description |
|---|---|
| private final int | |
| private final int | |
| private final boolean |
| Access | Constructor and Description |
|---|---|
| public | SampledCounterConfig(int
the interval (in seconds) between sampling intervalSecs, int number of counter samples that will be retained in memory historySize, boolean true if the counter should be reset to 0 upon each sample isResetOnSample, long the initial value given to this counter initialValue)Make a new timed counter config (duh) |
| Modifier and Type | Method and Description |
|---|---|
| public Counter | createCounter()
Overrides net. |
| public int | |
| public int | Returns: Interval of the sampling thread in secondsReturns the interval time (seconds) |
| public boolean | Returns: true if values are reset to the initial value after each sampleReturns true if counters created from this config will reset on each sample |
| historySize | back to summary |
|---|---|
| private final int historySize | |
| intervalSecs | back to summary |
|---|---|
| private final int intervalSecs | |
| isReset | back to summary |
|---|---|
| private final boolean isReset | |
| SampledCounterConfig | back to summary |
|---|---|
| public SampledCounterConfig(int intervalSecs, int historySize, boolean isResetOnSample, long initialValue) Make a new timed counter config (duh)
| |
| createCounter | back to summary |
|---|---|
| public Counter createCounter() Overrides net. Doc from net. Creates and returns a Counter based on the initial value | |
| getHistorySize | back to summary |
|---|---|
| public int getHistorySize() Returns the history size
| |
| getIntervalSecs | back to summary |
|---|---|
| public int getIntervalSecs() Returns the interval time (seconds)
| |
| isResetOnSample | back to summary |
|---|---|
| public boolean isResetOnSample() Returns true if counters created from this config will reset on each sample
| |