Package org.kairosdb.metrics4j.internal
Class ReportedMetricImpl
- java.lang.Object
-
- org.kairosdb.metrics4j.internal.ReportedMetricImpl
-
- All Implemented Interfaces:
ReportedMetric
public class ReportedMetricImpl extends Object implements ReportedMetric
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classReportedMetricImpl.SampleImpl-
Nested classes/interfaces inherited from interface org.kairosdb.metrics4j.reporting.ReportedMetric
ReportedMetric.Sample
-
-
Constructor Summary
Constructors Constructor Description ReportedMetricImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ReportedMetricImpl.SampleImpladdSample(String fieldName, MetricValue value)ReportedMetricImpladdTags(Map<String,String> tags)Adds tags that override what was already set.StringgetClassName()Map<String,String>getContext()StringgetMethodName()List<ReportedMetric.Sample>getSamples()Map<String,String>getTags()ReportedMetricImplsetClassName(String className)voidsetContext(Map<String,String> context)ReportedMetricImplsetMethodName(String methodName)ReportedMetricImplsetTags(Map<String,String> tags)ReportedMetricImplsetTime(Instant time)
-
-
-
Method Detail
-
setTime
public ReportedMetricImpl setTime(Instant time)
-
getClassName
public String getClassName()
- Specified by:
getClassNamein interfaceReportedMetric
-
setClassName
public ReportedMetricImpl setClassName(String className)
-
getMethodName
public String getMethodName()
- Specified by:
getMethodNamein interfaceReportedMetric
-
setMethodName
public ReportedMetricImpl setMethodName(String methodName)
-
getTags
public Map<String,String> getTags()
- Specified by:
getTagsin interfaceReportedMetric
-
setTags
public ReportedMetricImpl setTags(Map<String,String> tags)
-
addTags
public ReportedMetricImpl addTags(Map<String,String> tags)
Adds tags that override what was already set.- Parameters:
tags- Tags to add- Returns:
- This reference
-
getContext
public Map<String,String> getContext()
- Specified by:
getContextin interfaceReportedMetric
-
addSample
public ReportedMetricImpl.SampleImpl addSample(String fieldName, MetricValue value)
-
getSamples
public List<ReportedMetric.Sample> getSamples()
- Specified by:
getSamplesin interfaceReportedMetric
-
-