TimeStatisticImpl (ActiveMQ 1.1 API)
Keywords: org.codehaus.activemq.management.TimeStatisticImpl class

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.codehaus.activemq.management
Class TimeStatisticImpl

    java.lang.Object
      org.codehaus.activemq.management.StatisticImpl
          org.codehaus.activemq.management.TimeStatisticImpl

All Implemented Interfaces:
  Resettable, Statistic, TimeStatistic

public class TimeStatisticImpl
extends StatisticImpl
implements TimeStatistic

A time statistic implementation

Version:
  $Revision: 1.7 $

Constructor Summary
`TimeStatisticImpl(String name, String description)`
`TimeStatisticImpl(String name, String unit, String description)`
`TimeStatisticImpl(TimeStatisticImpl parent, String name, String description)`

Method Summary
`void` | `addTime(long time)`
`protected void` | `appendFieldDescription(StringBuffer buffer)`
`double` | `getAveragePerSecond()`
`double` | `getAveragePerSecondExcludingMinMax()`
`double` | `getAverageTime()`
`double` | `getAverageTimeExcludingMinMax()`
`long` | `getCount()`
`long` | `getMaxTime()`
`long` | `getMinTime()`
`TimeStatisticImpl` | `getParent()`
`long` | `getTotalTime()`
`void` | `reset()` Reset the statistic
`void` | `setParent(TimeStatisticImpl parent)`

Methods inherited from class org.codehaus.activemq.management.StatisticImpl
`getDescription, getLastSampleTime, getName, getStartTime, getUnit, toString, updateSampleTime`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Methods inherited from interface javax.management.j2ee.statistics.Statistic
`getDescription, getLastSampleTime, getName, getStartTime, getUnit`

Constructor Detail

### TimeStatisticImpl

    public TimeStatisticImpl(String name,
                             String description)

### TimeStatisticImpl

    public TimeStatisticImpl(TimeStatisticImpl parent,
                             String name,
                             String description)

### TimeStatisticImpl

    public TimeStatisticImpl(String name,
                             String unit,
                             String description)

Method Detail

### reset

    public void reset()

  Description copied from interface: `Resettable`
  Reset the statistic

  Specified by:
    `reset` in interface `Resettable`
  Overrides:
    `reset` in class `StatisticImpl`

### getCount

    public long getCount()

  Specified by:
    `getCount` in interface `TimeStatistic`

### addTime

    public void addTime(long time)

### getMaxTime

    public long getMaxTime()

  Specified by:
    `getMaxTime` in interface `TimeStatistic`
  Returns:
    the maximum time of any step

### getMinTime

    public long getMinTime()

  Specified by:
    `getMinTime` in interface `TimeStatistic`
  Returns:
    the minimum time of any step

### getTotalTime

    public long getTotalTime()

  Specified by:
    `getTotalTime` in interface `TimeStatistic`
  Returns:
    the total time of all the steps added together

### getAverageTime

    public double getAverageTime()

  Returns:
    the average time calculated by dividing the total time by the number of counts

### getAverageTimeExcludingMinMax

    public double getAverageTimeExcludingMinMax()

  Returns:
    the average time calculated by dividing the total time by the number of counts but excluding the minimum and maximum times.

### getAveragePerSecond

    public double getAveragePerSecond()

  Returns:
    the average number of steps per second

### getAveragePerSecondExcludingMinMax

    public double getAveragePerSecondExcludingMinMax()

  Returns:
    the average number of steps per second excluding the min & max values

### getParent

    public TimeStatisticImpl getParent()

### setParent

    public void setParent(TimeStatisticImpl parent)

### appendFieldDescription

    protected void appendFieldDescription(StringBuffer buffer)

  Overrides:
    `appendFieldDescription` in class `StatisticImpl`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004 Protique, Ltd.. All Rights Reserved.