Ping plugin

Closes #167
This commit is contained in:
Cameron Sparr
2015-09-02 17:16:52 -06:00
parent 65b33a848e
commit 68e41f130c
7 changed files with 416 additions and 7 deletions

View File

@@ -151,3 +151,14 @@ func (a *Accumulator) HasFloatValue(measurement string) bool {
return false
}
// HasMeasurement returns true if the accumulator has a measurement with the
// given name
func (a *Accumulator) HasMeasurement(measurement string) bool {
for _, p := range a.Points {
if p.Measurement == measurement {
return true
}
}
return false
}