/* Total count of values at the given timeseries level (all buckets). */
int64_t count(int level) const {
int64_t total = 0;
- for (int b = 0; b < buckets_.getNumBuckets(); ++b) {
+ for (unsigned int b = 0; b < buckets_.getNumBuckets(); ++b) {
total += buckets_.getByIndex(b).count(level);
}
return total;
/* Total count of values added during the given interval (all buckets). */
int64_t count(TimeType start, TimeType end) const {
int64_t total = 0;
- for (int b = 0; b < buckets_.getNumBuckets(); ++b) {
+ for (unsigned int b = 0; b < buckets_.getNumBuckets(); ++b) {
total += buckets_.getByIndex(b).count(start, end);
}
return total;
/* Total sum of values at the given timeseries level (all buckets). */
ValueType sum(int level) const {
ValueType total = ValueType();
- for (int b = 0; b < buckets_.getNumBuckets(); ++b) {
+ for (unsigned int b = 0; b < buckets_.getNumBuckets(); ++b) {
total += buckets_.getByIndex(b).sum(level);
}
return total;
/* Total sum of values added during the given interval (all buckets). */
ValueType sum(TimeType start, TimeType end) const {
ValueType total = ValueType();
- for (int b = 0; b < buckets_.getNumBuckets(); ++b) {
+ for (unsigned int b = 0; b < buckets_.getNumBuckets(); ++b) {
total += buckets_.getByIndex(b).sum(start, end);
}
return total;