Fixed JavaDoc in TMF UI plugin
[deliverable/tracecompass.git] / org.eclipse.linuxtools.tmf.ui / src / org / eclipse / linuxtools / tmf / ui / views / histogram / HistogramScaledData.java
index 648d7c8e382990da9391693eb07b7ecd7fdde65d..3d7b36b922d3d3b950bf03ed849604f96dd0dc1a 100644 (file)
@@ -17,9 +17,10 @@ package org.eclipse.linuxtools.tmf.ui.views.histogram;
 import java.util.Arrays;
 
 /**
- * <b><u>HistogramScaledData</u></b>
- * <p>
  * Convenience class/struct for scaled histogram data.
+ * 
+ * @version 1.0
+ * @author Francois Chouinard
  */
 public class HistogramScaledData {
 
@@ -27,28 +28,69 @@ public class HistogramScaledData {
     // Constants
     // ------------------------------------------------------------------------
 
+    /**
+     * Indicator value that bucket is out of range (not filled).
+     */
     public static final int OUT_OF_RANGE_BUCKET = -1;
 
     // ------------------------------------------------------------------------
     // Attributes
     // ------------------------------------------------------------------------
-
+    /**
+     * Width of histogram canvas (number of pixels).
+     */
     public int fWidth;
+    /**
+     * Height of histogram canvas (number of pixels).
+     */
     public int fHeight;
+    /**
+     * Width of one histogram bar (number of pixels). 
+     */
     public int fBarWidth;
+    /**
+     * Array of scaled values
+     */
     public int[] fData;
+    /**
+     * The bucket duration of a scaled data bucket.
+     */
     public long fBucketDuration;
+    /**
+     * The maximum number of events of all buckets. 
+     */
     public long fMaxValue;
+    /**
+     * The index of the current bucket.
+     */
     public int fCurrentBucket;
+    /**
+     * The index of the last bucket. 
+     */
     public int fLastBucket;
+    /**
+     * The scaling factor used to fill the scaled data.
+     */
     public double fScalingFactor;
+    /**
+     * Time of first bucket.
+     */
     public long fFirstBucketTime;
+    /**
+     * The time of the first event.
+     */
     public long fFirstEventTime;
 
     // ------------------------------------------------------------------------
     // Constructor
     // ------------------------------------------------------------------------
 
+    /**
+     * Constructor.
+     * @param width the canvas width
+     * @param height the canvas height
+     * @param barWidth the required bar width
+     */
     public HistogramScaledData(int width, int height, int barWidth) {
         fWidth = width;
         fHeight = height;
@@ -63,6 +105,10 @@ public class HistogramScaledData {
         fFirstBucketTime = 0;
     }
 
+    /**
+     * Copy constructor
+     * @param other another scaled data.
+     */
     public HistogramScaledData(HistogramScaledData other) {
         fWidth = other.fWidth;
         fHeight = other.fHeight;
@@ -80,24 +126,45 @@ public class HistogramScaledData {
     // Setter and Getter
     // ------------------------------------------------------------------------
 
+    /**
+     * Returns the time of the first bucket of the scaled data.
+     * @return the time of the first bucket.
+     */
     public long getFirstBucketTime() {
         return fFirstBucketTime;
     }
 
+    /**
+     * Set the first event time. 
+     * @param firstEventTime
+     */
     public void setFirstBucketTime(long firstEventTime) {
         fFirstBucketTime = firstEventTime;
     }
     
+    /**
+     * Returns the time of the last bucket.
+     * @return last bucket time
+     */
     public long getLastBucketTime() {
         return getBucketStartTime(fLastBucket);
     }
     
+    /**
+     * Returns the time of the bucket start time for given index.
+     * @param index A bucket index.
+     * @return the time of the bucket start time
+     */
     public long getBucketStartTime(int index) {
         return fFirstBucketTime + index * fBucketDuration;
     }
     
+    /**
+     * Returns the time of the bucket end time for given index.
+     * @param index A bucket index.
+     * @return the time of the bucket end time
+     */
     public long getBucketEndTime(int index) {
         return getBucketStartTime(index) + fBucketDuration;
     }
-
 }
\ No newline at end of file
This page took 0.02579 seconds and 5 git commands to generate.