Class PerformanceMetrics
java.lang.Object
org.deltava.beans.stats.PerformanceMetrics
- All Implemented Interfaces:
Serializable
,Comparable<PerformanceMetrics>
,AuthoredBean
public class PerformanceMetrics
extends Object
implements Serializable, AuthoredBean, Comparable<PerformanceMetrics>
A bean to track performance metrics data.
- Since:
- 1.0
- Version:
- 7.2
- Author:
- Luke
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
Compares two entries by comparing their category names.int
Returns the Author of this bean.double
Returns the average.long
getCount()
Returns the category count.double
Returns the maximum value.double
Returns the minimum value.getName()
Returns the category name.int
hashCode()
void
setAuthorID
(int id) Updates the author of this bean.void
setAverage
(double avg) Updates the average value.void
setCount
(long count) Updates the category count.void
setLimits
(double mn, double mx) Updates the data series limits.void
Updates the category name.
-
Constructor Details
-
PerformanceMetrics
Creates a new performance metrics bean.- Parameters:
catName
- the category name- Throws:
NullPointerException
- if catName is null- See Also:
-
-
Method Details
-
getName
-
getCount
public long getCount()Returns the category count.- Returns:
- the count
-
getAverage
public double getAverage()Returns the average.- Returns:
- the average
-
getMaximum
public double getMaximum()Returns the maximum value.- Returns:
- the maximum
-
getMinimum
public double getMinimum()Returns the minimum value.- Returns:
- the minimum
-
getAuthorID
public int getAuthorID()Description copied from interface:AuthoredBean
Returns the Author of this bean.- Specified by:
getAuthorID
in interfaceAuthoredBean
- Returns:
- the author's database ID
- See Also:
-
setName
Updates the category name.- Parameters:
name
- the category name- Throws:
NullPointerException
- if name is null
-
setAverage
public void setAverage(double avg) Updates the average value.- Parameters:
avg
- the average
-
setCount
public void setCount(long count) Updates the category count.- Parameters:
count
- the count
-
setLimits
public void setLimits(double mn, double mx) Updates the data series limits.- Parameters:
mn
- the minimummx
- the maximum
-
setAuthorID
public void setAuthorID(int id) Description copied from interface:AuthoredBean
Updates the author of this bean.- Specified by:
setAuthorID
in interfaceAuthoredBean
- Parameters:
id
- the author's database ID.- See Also:
-
compareTo
Compares two entries by comparing their category names.- Specified by:
compareTo
in interfaceComparable<PerformanceMetrics>
-
hashCode
-