public class DefaultIntervalProperty extends Object implements IntervalProperty
IntervalProperty| Constructor and Description |
|---|
DefaultIntervalProperty(String name)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
String |
getName()
Return the property name.
|
String |
getValue()
Return the value.
|
void |
refresh()
Signal to update the property value.
|
protected String value
public DefaultIntervalProperty(String name)
name - Property key name. The property key name is also
used when the property is logged to identify the value.public String getName()
getName in interface IntervalPropertypublic String getValue()
getValue in interface IntervalPropertypublic void refresh()
public void refresh() {
value = Long.toString(Runtime.getRuntime().totalMemory());
}
Specific refresh behavior depends upon the type of property. As general rule
if your data does not change then you should consider logging the data
outside the status message.refresh in interface IntervalPropertyrefresh()Copyright © 2021. All rights reserved.