public class MutableCountStatisticImpl extends Object implements javax.management.j2ee.statistics.CountStatistic, MutableCountStatistic
for an immutable implementation,
Serialized Form| Constructor and Description |
|---|
MutableCountStatisticImpl(javax.management.j2ee.statistics.CountStatistic initial)
Constructs an instance of MutableCountStatistic that encapsulates the given Statistic.
|
| Modifier and Type | Method and Description |
|---|---|
long |
getCount() |
String |
getDescription() |
long |
getLastSampleTime() |
String |
getName() |
long |
getStartTime() |
String |
getUnit() |
javax.management.j2ee.statistics.Statistic |
modifiableView()
Returns an instance of Statistic whose state can be changed by the caller.
|
void |
reset()
Resets to the initial state.
|
void |
setCount(long count)
Changes the value of the encapsulated CountStatistic to the given value.
|
void |
setDescription(String s) |
javax.management.j2ee.statistics.Statistic |
unmodifiableView()
This method is the essence of this class.
|
public MutableCountStatisticImpl(javax.management.j2ee.statistics.CountStatistic initial)
initial - an instance of CountStatistic that represents initial statepublic void reset()
reset in interface MutableStatisticpublic void setCount(long count)
setCount in interface MutableCountStatisticcount - long that represents the current value of the Statistic.public javax.management.j2ee.statistics.Statistic unmodifiableView()
unmodifiableView in interface MutableStatisticreset(),
setCount(long)public long getLastSampleTime()
getLastSampleTime in interface javax.management.j2ee.statistics.Statisticpublic long getStartTime()
getStartTime in interface javax.management.j2ee.statistics.Statisticpublic String getName()
getName in interface javax.management.j2ee.statistics.Statisticpublic String getDescription()
getDescription in interface javax.management.j2ee.statistics.Statisticpublic String getUnit()
getUnit in interface javax.management.j2ee.statistics.Statisticpublic javax.management.j2ee.statistics.Statistic modifiableView()
MutableStatisticmodifiableView in interface MutableStatisticpublic long getCount()
getCount in interface javax.management.j2ee.statistics.CountStatisticpublic void setDescription(String s)
Copyright © 2019. All rights reserved.