Package io.opencensus.metrics.export
Class Summary
- java.lang.Object
-
- io.opencensus.metrics.export.Summary
-
- Direct Known Subclasses:
AutoValue_Summary
@ExperimentalApi @Immutable public abstract class Summary extends java.lang.Object
Implementation of theDistribution
as a summary of observations.This is not recommended, since it cannot be aggregated.
- Since:
- 0.17
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Summary.Snapshot
Represents the summary observation of the recorded events over a sliding time window.
-
Constructor Summary
Constructors Constructor Description Summary()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description private static void
checkCountAndSum(java.lang.Long count, java.lang.Double sum)
static Summary
create(java.lang.Long count, java.lang.Double sum, Summary.Snapshot snapshot)
Creates aSummary
.abstract java.lang.Long
getCount()
Returns the aggregated count.abstract Summary.Snapshot
getSnapshot()
Returns theSummary.Snapshot
.abstract java.lang.Double
getSum()
Returns the aggregated sum.
-
-
-
Method Detail
-
create
public static Summary create(@Nullable java.lang.Long count, @Nullable java.lang.Double sum, Summary.Snapshot snapshot)
Creates aSummary
.- Parameters:
count
- the count of the population values.sum
- the sum of the population values.snapshot
- bucket boundaries of a histogram.- Returns:
- a
Summary
with the given values. - Since:
- 0.17
-
getCount
@Nullable public abstract java.lang.Long getCount()
Returns the aggregated count. If not available returnsnull
.- Returns:
- the aggregated count.
- Since:
- 0.17
-
getSum
@Nullable public abstract java.lang.Double getSum()
Returns the aggregated sum. If not available returnsnull
.- Returns:
- the aggregated sum.
- Since:
- 0.17
-
getSnapshot
public abstract Summary.Snapshot getSnapshot()
Returns theSummary.Snapshot
.- Returns:
- the
Snapshot
. - Since:
- 0.17
-
checkCountAndSum
private static void checkCountAndSum(@Nullable java.lang.Long count, @Nullable java.lang.Double sum)
-
-