@@ -169,7 +169,7 @@ pub struct GaugeDataPoint<T> {
169169 /// time series.
170170 pub ( crate ) attributes : Vec < KeyValue > ,
171171 /// The value of this data point.
172- pub value : T ,
172+ pub ( crate ) value : T ,
173173 /// The sampled [Exemplar]s collected during the time series.
174174 pub ( crate ) exemplars : Vec < Exemplar < T > > ,
175175}
@@ -226,7 +226,7 @@ pub struct SumDataPoint<T> {
226226 /// time series.
227227 pub ( crate ) attributes : Vec < KeyValue > ,
228228 /// The value of this data point.
229- pub value : T ,
229+ pub ( crate ) value : T ,
230230 /// The sampled [Exemplar]s collected during the time series.
231231 pub ( crate ) exemplars : Vec < Exemplar < T > > ,
232232}
@@ -269,23 +269,23 @@ impl<T> Sum<T> {
269269 pub fn data_points ( & self ) -> impl Iterator < Item = & SumDataPoint < T > > {
270270 self . data_points . iter ( )
271271 }
272-
272+
273273 /// Returns the time when the time series was started.
274274 pub fn start_time ( & self ) -> SystemTime {
275275 self . start_time
276276 }
277-
277+
278278 /// Returns the time when the time series was recorded.
279279 pub fn time ( & self ) -> SystemTime {
280280 self . time
281281 }
282-
283- /// Returns the temporality describing if the aggregation is reported as the change
282+
283+ /// Returns the temporality describing if the aggregation is reported as the change
284284 /// from the last report time, or the cumulative changes since a fixed start time.
285285 pub fn temporality ( & self ) -> Temporality {
286286 self . temporality
287287 }
288-
288+
289289 /// Returns whether this aggregation only increases or decreases.
290290 pub fn is_monotonic ( & self ) -> bool {
291291 self . is_monotonic
@@ -311,18 +311,18 @@ impl<T> Histogram<T> {
311311 pub fn data_points ( & self ) -> impl Iterator < Item = & HistogramDataPoint < T > > {
312312 self . data_points . iter ( )
313313 }
314-
314+
315315 /// Returns the time when the time series was started.
316316 pub fn start_time ( & self ) -> SystemTime {
317317 self . start_time
318318 }
319-
319+
320320 /// Returns the time when the time series was recorded.
321321 pub fn time ( & self ) -> SystemTime {
322322 self . time
323323 }
324-
325- /// Returns the temporality describing if the aggregation is reported as the change
324+
325+ /// Returns the temporality describing if the aggregation is reported as the change
326326 /// from the last report time, or the cumulative changes since a fixed start time.
327327 pub fn temporality ( & self ) -> Temporality {
328328 self . temporality
@@ -374,22 +374,22 @@ impl<T> HistogramDataPoint<T> {
374374 pub fn bucket_counts ( & self ) -> impl Iterator < Item = u64 > + ' _ {
375375 self . bucket_counts . iter ( ) . copied ( )
376376 }
377-
377+
378378 /// Returns the number of updates this histogram has been calculated with.
379379 pub fn count ( & self ) -> u64 {
380380 self . count
381381 }
382-
382+
383383 /// Returns the minimum value recorded.
384384 pub fn min ( & self ) -> Option < & T > {
385385 self . min . as_ref ( )
386386 }
387-
387+
388388 /// Returns the maximum value recorded.
389389 pub fn max ( & self ) -> Option < & T > {
390390 self . max . as_ref ( )
391391 }
392-
392+
393393 /// Returns the sum of the values recorded.
394394 pub fn sum ( & self ) -> & T {
395395 & self . sum
@@ -415,18 +415,18 @@ impl<T> ExponentialHistogram<T> {
415415 pub fn data_points ( & self ) -> impl Iterator < Item = & ExponentialHistogramDataPoint < T > > {
416416 self . data_points . iter ( )
417417 }
418-
418+
419419 /// Returns the time when the time series was started.
420420 pub fn start_time ( & self ) -> SystemTime {
421421 self . start_time
422422 }
423-
423+
424424 /// Returns the time when the time series was recorded.
425425 pub fn time ( & self ) -> SystemTime {
426426 self . time
427427 }
428-
429- /// Returns the temporality describing if the aggregation is reported as the change
428+
429+ /// Returns the temporality describing if the aggregation is reported as the change
430430 /// from the last report time, or the cumulative changes since a fixed start time.
431431 pub fn temporality ( & self ) -> Temporality {
432432 self . temporality
@@ -488,47 +488,47 @@ impl<T> ExponentialHistogramDataPoint<T> {
488488 pub fn exemplars ( & self ) -> impl Iterator < Item = & Exemplar < T > > {
489489 self . exemplars . iter ( )
490490 }
491-
491+
492492 /// Returns the number of updates this histogram has been calculated with.
493493 pub fn count ( & self ) -> usize {
494494 self . count
495495 }
496-
496+
497497 /// Returns the minimum value recorded.
498498 pub fn min ( & self ) -> Option < & T > {
499499 self . min . as_ref ( )
500500 }
501-
501+
502502 /// Returns the maximum value recorded.
503503 pub fn max ( & self ) -> Option < & T > {
504504 self . max . as_ref ( )
505505 }
506-
506+
507507 /// Returns the sum of the values recorded.
508508 pub fn sum ( & self ) -> & T {
509509 & self . sum
510510 }
511-
511+
512512 /// Returns the resolution of the histogram.
513513 pub fn scale ( & self ) -> i8 {
514514 self . scale
515515 }
516-
516+
517517 /// Returns the number of values whose absolute value is less than or equal to zero_threshold.
518518 pub fn zero_count ( & self ) -> u64 {
519519 self . zero_count
520520 }
521-
521+
522522 /// Returns the range of positive value bucket counts.
523523 pub fn positive_bucket ( & self ) -> & ExponentialBucket {
524524 & self . positive_bucket
525525 }
526-
526+
527527 /// Returns the range of negative value bucket counts.
528528 pub fn negative_bucket ( & self ) -> & ExponentialBucket {
529529 & self . negative_bucket
530530 }
531-
531+
532532 /// Returns the width of the zero region.
533533 pub fn zero_threshold ( & self ) -> f64 {
534534 self . zero_threshold
@@ -553,7 +553,7 @@ impl ExponentialBucket {
553553 pub fn offset ( & self ) -> i32 {
554554 self . offset
555555 }
556-
556+
557557 /// Returns a reference to the counts vec.
558558 pub fn counts ( & self ) -> & [ u64 ] {
559559 & self . counts
0 commit comments