ca.utoronto.JCVSReport.metric
Class MetricRevision

java.lang.Object
  extended byjava.util.AbstractCollection
      extended byjava.util.AbstractList
          extended byjava.util.Vector
              extended byca.utoronto.JCVSReport.metric.MetricRevision
All Implemented Interfaces:
Cloneable, Collection, List, RandomAccess, Serializable

public class MetricRevision
extends Vector

The result of a query for a metric in the Metric Database

Author:
David James
See Also:
Serialized Form

Field Summary
 
Fields inherited from class java.util.Vector
capacityIncrement, elementCount, elementData
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
MetricRevision(List list)
          Create a MetricRevision object from a list
MetricRevision(ResultSet resultSet)
          Initialize a MetricRevision object from the keys of a query
MetricRevision(String metricName, String file, Timestamp tstamp, double metricValue, String developer)
          Create a MetricRevision object from a string
 
Method Summary
static Comparator byDeveloper()
          Sort this metric by metric name and developer Note: this comparator imposes orderings that are inconsistent with equals
static Comparator byFile()
          Sort this metric by metric name and file Note: this comparator imposes orderings that are inconsistent with equals
 org.jfree.data.time.Day getDay()
          Get the timestamp as a day
 String getDeveloper()
          Get the metric value
 String getFile()
          Get the filename
 String getMetricName()
          Get the title
 double getMetricValue()
          Get the metric value
 Timestamp getTimestamp()
          Get the timestamp
 
Methods inherited from class java.util.Vector
add, add, addAll, addAll, addElement, capacity, clear, clone, contains, containsAll, copyInto, elementAt, elements, ensureCapacity, equals, firstElement, get, hashCode, indexOf, indexOf, insertElementAt, isEmpty, lastElement, lastIndexOf, lastIndexOf, remove, remove, removeAll, removeAllElements, removeElement, removeElementAt, removeRange, retainAll, set, setElementAt, setSize, size, subList, toArray, toArray, toString, trimToSize
 
Methods inherited from class java.util.AbstractList
iterator, listIterator, listIterator
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
iterator, listIterator, listIterator
 

Constructor Detail

MetricRevision

public MetricRevision(ResultSet resultSet)
               throws SQLException
Initialize a MetricRevision object from the keys of a query

Parameters:
resultSet - The query to read

MetricRevision

public MetricRevision(List list)
Create a MetricRevision object from a list

Parameters:
list - the list to read from

MetricRevision

public MetricRevision(String metricName,
                      String file,
                      Timestamp tstamp,
                      double metricValue,
                      String developer)
Create a MetricRevision object from a string

Parameters:
metricName - metric name
file - the filename changed in this revision
tstamp - timestamp of change
metricValue - value of metric
developer - the name of the developer who committed this change
Method Detail

getMetricName

public String getMetricName()
Get the title


getFile

public String getFile()
Get the filename


getTimestamp

public Timestamp getTimestamp()
Get the timestamp


getDay

public org.jfree.data.time.Day getDay()
Get the timestamp as a day


getMetricValue

public double getMetricValue()
Get the metric value


getDeveloper

public String getDeveloper()
Get the metric value


byDeveloper

public static Comparator byDeveloper()
Sort this metric by metric name and developer Note: this comparator imposes orderings that are inconsistent with equals


byFile

public static Comparator byFile()
Sort this metric by metric name and file Note: this comparator imposes orderings that are inconsistent with equals



JCVSReport: Easy Progress Reports for CVS/Java Projects. By David James.