Bundle-ManifestVersion: 2
Bundle-Name: %Bundle-Name
Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
+Bundle-Version: 1.1.0.qualifier
Bundle-Localization: plugin
Bundle-SymbolicName: org.eclipse.tracecompass.analysis.timing.core;singleton:=true
Bundle-Activator: org.eclipse.tracecompass.internal.analysis.timing.core.Activator
private long fNbSegments;
private double fAverage;
private double fVariance;
+ private double fTotal;
/**
* Constructor
fNbSegments = 0;
fAverage = 0.0;
fVariance = 0.0;
+ fTotal = 0.0;
}
/**
double delta = value - fAverage;
fAverage += delta / fNbSegments;
fVariance += delta * (value - fAverage);
+ fTotal += value;
+ }
+
+ /**
+ * Get total value
+ *
+ * @return total value
+ * @since 1.1
+ */
+ public double getTotal() {
+ return fTotal;
}
}
Bundle-ManifestVersion: 2
Bundle-Name: %Bundle-Name
Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
+Bundle-Version: 1.1.0.qualifier
Bundle-Localization: plugin
Bundle-SymbolicName: org.eclipse.tracecompass.analysis.timing.ui;singleton:=true
Bundle-Activator: org.eclipse.tracecompass.internal.analysis.timing.ui.Activator
checkNotNull(Messages.SegmentStoreStatistics_MaxLabel),
checkNotNull(Messages.SegmentStoreStatistics_AverageLabel),
checkNotNull(Messages.SegmentStoreStatisticsViewer_StandardDeviation),
- checkNotNull(Messages.SegmentStoreStatisticsViewer_Count)
+ checkNotNull(Messages.SegmentStoreStatisticsViewer_Count),
+ checkNotNull(Messages.SegmentStoreStatisticsViewer_Total)
};
/**
value = String.valueOf(toFormattedString(entry.getEntry().getStdDev()));
} else if (columnIndex == 5) {
value = String.valueOf(entry.getEntry().getNbSegments());
+ } else if (columnIndex == 6) {
+ value = String.valueOf(toFormattedString(entry.getEntry().getTotal()));
}
}
}
}
});
columns.add(column);
+ column = new TmfTreeColumnData(COLUMN_NAMES[6]);
+ column.setAlignment(SWT.RIGHT);
+ column.setComparator(new ViewerComparator() {
+ @Override
+ public int compare(@Nullable Viewer viewer, @Nullable Object e1, @Nullable Object e2) {
+ if ((e1 == null) || (e2 == null)) {
+ return 0;
+ }
+
+ SegmentStoreStatisticsEntry n1 = (SegmentStoreStatisticsEntry) e1;
+ SegmentStoreStatisticsEntry n2 = (SegmentStoreStatisticsEntry) e2;
+
+ return Double.compare(n1.getEntry().getTotal(), n2.getEntry().getTotal());
+
+ }
+ });
+ columns.add(column);
column = new TmfTreeColumnData(""); //$NON-NLS-1$
columns.add(column);
return columns;
public static String SegmentStoreStatistics_AverageLabel;
/** Name of count column */
public static String SegmentStoreStatisticsViewer_Count;
+ /**
+ * Name of count column
+ *
+ * @since 1.1
+ */
+ public static String SegmentStoreStatisticsViewer_Total;
/** Name of average column */
public static String SegmentStoreStatisticsViewer_StandardDeviation;
/** Menu item for go to minimum duration */
SegmentStoreStatistics_MaxLabel=Maximum
SegmentStoreStatistics_AverageLabel=Average
SegmentStoreStatisticsViewer_Count=Count
+SegmentStoreStatisticsViewer_Total=Total
SegmentStoreStatisticsViewer_StandardDeviation=Standard Deviation
SegmentStoreStatisticsViewer_GotoMinAction=Go to minimum
SegmentStoreStatisticsViewer_GotoMaxAction=Go to maximum
\ No newline at end of file