Report.java :  » Profiler » stopwatch » com » commsen » stopwatch » Java Open Source

Java Open Source » Profiler » stopwatch 
stopwatch » com » commsen » stopwatch » Report.java
/*
 * $Id: Report.java,v 1.1 2006/03/01 17:48:04 azzazzel Exp $
 *
 * Copyright 2006 Commsen International
 * 
 * Licensed under the Common Public License, Version 1.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * 
 *      http://www.opensource.org/licenses/cpl1.0.txt
 * 
 * THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, 
 * EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS 
 * OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
 *
 */
package com.commsen.stopwatch;

import java.io.Serializable;

/**
 * Basic stopwatch report. 
 * All reports generated by stopwatch storages should implement this interface. 
 *
 * @author Milen Dyankov
 *
 */
public interface Report extends Serializable {
  
  /**
   * Information about the group for which this report was generated.
   * If <code>null</code> then this is summary report for given lebel (as
   * returned by {@link #getLabel()}) in all groups. 
   * 
   * @return the name of the group
   */
  public String getGroup();
  
  
  /**
   * Information about the label for which this report was generated.
   * If <code>null</code> then this is summary report for all lebels in given group (as
   * returned by {@link #getGroup()}). 
   * 
   * @return the label
   */
  public String getLabel();

  
  /**
   * The minimal of all completed measurements for this label and/or group  
   * @return minimal of all times measured
   */
  public double getMinTime();
  
  
  /**
   * The maximal of all completed measurements for this label and/or group  
   * @return maximal of all completed measurements
   */
  public double getMaxTime();

  
  /**
   * The average of all completed measurements for this label and/or group
   * @return average of all completed measurements
   */
  public double getAverageTime();

  /**
   * The sum of all completed measurements for this label and/or group
   * @return sum of all completed measurements
   */
  public double getTotalTime();
  
  /**
   * The number of all completed measurements for this label and/or group
   * @return number of all completed measurements
   */
  public long getCount();
  
}
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.