public abstract class AbstractSimonMXBeanImpl extends Object implements SimonSuperMXBean
Constructor and Description |
---|
AbstractSimonMXBeanImpl() |
Modifier and Type | Method and Description |
---|---|
List<String> |
getChildrenNames()
Returns list of children names.
|
long |
getFirstUsage()
Returns ms timestamp of the first usage of this Simon.
|
String |
getFirstUsageAsString()
Returns nicely formatted timestamp of the first usage of this Simon.
|
long |
getLastUsage()
Returns ms timestamp of the last usage of this Simon.
|
String |
getLastUsageAsString()
Returns nicely formatted timestamp of the last usage of this Simon.
|
String |
getName()
Returns Simon name.
|
String |
getNote()
Returns note for the Simon.
|
String |
getParentName()
Returns name of the parent Simon.
|
String |
getState()
Returns state of the Simon that can be ENABLED, DISABLED or INHERITED.
|
boolean |
isEnabled()
Returns true, if the Simon is enabled or if the enabled state is inherited.
|
void |
setNote(String note)
Sets note for the Simon.
|
void |
setState(String state,
boolean overrule)
Sets the state of the Simon.
|
protected abstract Simon |
simon()
Returns the wrapped Simon.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getType, sample, sampleIncrement, stopIncrementalSampling
public AbstractSimonMXBeanImpl()
public final String getName()
SimonSuperMXBean
null
for anonymous
Simons, such Simons are never registered hence this method never returns
null
.getName
in interface SimonSuperMXBean
public final String getParentName()
SimonSuperMXBean
getParentName
in interface SimonSuperMXBean
public final List<String> getChildrenNames()
SimonSuperMXBean
getChildrenNames
in interface SimonSuperMXBean
public final String getState()
SimonSuperMXBean
SimonState
enumeration.getState
in interface SimonSuperMXBean
public final void setState(String state, boolean overrule)
SimonSuperMXBean
setState
in interface SimonSuperMXBean
state
- a new state as a valid String for SimonState.valueOf(String)
overrule
- specifies whether this change is forced to the whole subtree.public final boolean isEnabled()
SimonSuperMXBean
isEnabled
in interface SimonSuperMXBean
public final String getNote()
SimonSuperMXBean
getNote
in interface SimonSuperMXBean
public final void setNote(String note)
SimonSuperMXBean
setNote
in interface SimonSuperMXBean
note
- note for the Simon.public final long getFirstUsage()
SimonSuperMXBean
getFirstUsage
in interface SimonSuperMXBean
public String getFirstUsageAsString()
SimonSuperMXBean
getFirstUsageAsString
in interface SimonSuperMXBean
public final long getLastUsage()
SimonSuperMXBean
getLastUsage
in interface SimonSuperMXBean
public final String getLastUsageAsString()
SimonSuperMXBean
getLastUsageAsString
in interface SimonSuperMXBean
Copyright © 2019. All rights reserved.