intarsys runtime library

de.intarsys.tools.monitor
Class Monitor

java.lang.Object
  extended by de.intarsys.tools.monitor.AbstractMonitor
      extended by de.intarsys.tools.monitor.Monitor
All Implemented Interfaces:
IElementConfigurable, IMonitor
Direct Known Subclasses:
CounterMonitor, MemberMonitor, MemoryMonitor, TimeMonitor

public abstract class Monitor
extends AbstractMonitor

todo 1 nested traces todo 1 refactor "sample" changes in TimeMonitor todo 1 nicht matchende samples unterstützen


Field Summary
static String ATTR_AVG
           
static String ATTR_COUNT
           
static String ATTR_EFFECTIVE
           
static String ATTR_FIRST
           
static String ATTR_LAST
           
static String ATTR_MAX
           
static String ATTR_MAXACTIVE
           
static String ATTR_MIN
           
static String ATTR_NAME
          The collected attributes
static String ATTR_TOTAL
           
 
Constructor Summary
Monitor()
           
Monitor(String name)
          Create a Monitor.
 
Method Summary
 void configure(Element element)
           
 int getActive()
           
 Map getData()
          A map containing key/value pairs representing all statistical informations derived from the samples.
 Map getFormattedData()
          A map containing key/value pairs with string representations for the statistical information from getData.
 boolean isRelative()
          DOCUMENT ME!
 void reset()
          Reset the relevant internal state of the monitor to reuse it.
 void setRelative(boolean relative)
           
 String toString()
           
 String toTableString()
           
 
Methods inherited from class de.intarsys.tools.monitor.AbstractMonitor
attach, detach, getCollectAll, getCurrentTrace, getDefaultLevel, getLevel, getLogCycle, getLogger, getName, getTraces, setCollectAll, setDefaultLevel, setLevel, setLogCycle, setLogger, setName, start, stop
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

ATTR_NAME

public static final String ATTR_NAME
The collected attributes

See Also:
Constant Field Values

ATTR_MAX

public static final String ATTR_MAX
See Also:
Constant Field Values

ATTR_MIN

public static final String ATTR_MIN
See Also:
Constant Field Values

ATTR_COUNT

public static final String ATTR_COUNT
See Also:
Constant Field Values

ATTR_TOTAL

public static final String ATTR_TOTAL
See Also:
Constant Field Values

ATTR_EFFECTIVE

public static final String ATTR_EFFECTIVE
See Also:
Constant Field Values

ATTR_AVG

public static final String ATTR_AVG
See Also:
Constant Field Values

ATTR_FIRST

public static final String ATTR_FIRST
See Also:
Constant Field Values

ATTR_LAST

public static final String ATTR_LAST
See Also:
Constant Field Values

ATTR_MAXACTIVE

public static final String ATTR_MAXACTIVE
See Also:
Constant Field Values
Constructor Detail

Monitor

public Monitor()

Monitor

public Monitor(String name)
Create a Monitor.

Parameters:
name - The monitors name
Method Detail

configure

public void configure(Element element)
               throws ElementConfigurationException
Specified by:
configure in interface IElementConfigurable
Overrides:
configure in class AbstractMonitor
Throws:
ElementConfigurationException

getActive

public int getActive()

getData

public Map getData()
Description copied from interface: IMonitor
A map containing key/value pairs representing all statistical informations derived from the samples.

Returns:
A map containing key/value pairs representing all statistical informations derived from the samples.

getFormattedData

public Map getFormattedData()
Description copied from interface: IMonitor
A map containing key/value pairs with string representations for the statistical information from getData.

Returns:
A map containing key/value pairs with string representations for the statistical information from getData.

isRelative

public boolean isRelative()
DOCUMENT ME!

Returns:
Returns the relative.

reset

public void reset()
Reset the relevant internal state of the monitor to reuse it.

Specified by:
reset in interface IMonitor
Overrides:
reset in class AbstractMonitor

setRelative

public void setRelative(boolean relative)

toString

public String toString()
Overrides:
toString in class Object

toTableString

public String toTableString()

intarsys runtime library

Copyright © 2012 intarsys consulting GmbH. All Rights Reserved.