All Downloads are FREE. Search and download functionalities are using the official Maven repository.

patterntesting.runtime.monitor.ProfileMonitor Maven / Gradle / Ivy

Go to download

PatternTesting Runtime (patterntesting-rt) is the runtime component for the PatternTesting framework. It provides the annotations and base classes for the PatternTesting testing framework (e.g. patterntesting-check, patterntesting-concurrent or patterntesting-exception) but can be also used standalone for classpath monitoring or profiling. It uses AOP and AspectJ to perform this feat.

The newest version!
package patterntesting.runtime.monitor;

import java.util.Date;

/**
 * The Interface ProfileMonitor.
 */
public interface ProfileMonitor extends Comparable {

    /**
     * Gets the monitors.
     *
     * @return the monitors
     */
    public ProfileMonitor[] getMonitors();

    /**
     * Start.
     */
    public void start();

    /**
     * Stop.
     */
    public void stop();

    /**
     * Reset.
     */
    public void reset();

    /**
     * Gets the label.
     *
     * @return the label
     */
    public String getLabel();

    /**
     * Normally this method should be synchronized. But we waive it with the
     * risk that the measured time may be slightly wrong.
     *
     * @param value the value
     */
    public void add(double value);

    /**
     * Gets the total.
     *
     * @return the total
     */
    public double getTotal();

    /**
     * Gets the last value.
     *
     * @return the last value
     */
    public double getLastValue();

    /**
     * Gets the max.
     *
     * @return the max
     */
    public double getMax();

    /**
     * Gets the min.
     *
     * @return the min
     */
    public double getMin();

    /**
     * Gets the hits.
     *
     * @return the hits
     */
    public int getHits();

    /**
     * Gets the avg.
     *
     * @return the avg
     */
    public double getAvg();

    /**
     * To short string.
     *
     * @return the string
     */
    public String toShortString();

    /**
     * To csv string.
     *
     * @return the string
     */
    public String toCsvString();

    /**
     * To csv headline.
     *
     * @return the string
     */
    public String toCsvHeadline();

    /**
     * Gets the active.
     *
     * @return the active
     */
    public double getActive();

    /**
     * Gets the avg active.
     *
     * @return the avg active
     */
    public double getAvgActive();

    /**
     * Gets the max active.
     *
     * @return the max active
     */
    public double getMaxActive();

    /**
     * Gets the first access.
     *
     * @return the first access
     */
    public Date getFirstAccess();

    /**
     * Gets the last access.
     *
     * @return the last access
     */
    public Date getLastAccess();

    /**
     * Gets the units.
     *
     * @return the units
     */
    public String getUnits();

}

/**
 * $Log: ProfileMonitor.java,v $
 * Revision 1.12  2009/12/19 22:34:09  oboehm
 * trailing spaces removed
 *
 * Revision 1.11  2009/09/25 14:49:43  oboehm
 * javadocs completed with the help of JAutodoc
 *
 * Revision 1.10  2008/12/27 21:30:49  oboehm
 * Unit added to statistic tabular table
 *
 * Revision 1.9  2008/12/27 21:16:05  oboehm
 * getStatistics() added
 *
 * $Source: /cvsroot/patterntesting/PatternTesting08/patterntesting-rt/src/main/java/patterntesting/runtime/monitor/ProfileMonitor.java,v $
 */




© 2015 - 2024 Weber Informatics LLC | Privacy Policy