mirror of
https://github.com/ClusterCockpit/cc-metric-collector.git
synced 2024-12-25 23:19:06 +01:00
Add all CCMetric functions to interface
This commit is contained in:
parent
328d26bf3c
commit
4195786242
@ -22,14 +22,27 @@ type ccMetric struct {
|
|||||||
|
|
||||||
type CCMetric interface {
|
type CCMetric interface {
|
||||||
lp.MutableMetric
|
lp.MutableMetric
|
||||||
AddMeta(key, value string)
|
Name() string
|
||||||
MetaList() []*lp.Tag
|
AddTag(key, value string)
|
||||||
RemoveTag(key string)
|
|
||||||
GetTag(key string) (string, bool)
|
GetTag(key string) (string, bool)
|
||||||
|
HasTag(key string) bool
|
||||||
|
RemoveTag(key string)
|
||||||
|
Tags() map[string]string
|
||||||
|
TagList() []*lp.Tag
|
||||||
|
AddMeta(key, value string)
|
||||||
GetMeta(key string) (string, bool)
|
GetMeta(key string) (string, bool)
|
||||||
|
HasMeta(key string) bool
|
||||||
|
RemoveMeta(key string)
|
||||||
|
Meta() map[string]string
|
||||||
|
MetaList() []*lp.Tag
|
||||||
|
AddField(key string, value interface{})
|
||||||
GetField(key string) (interface{}, bool)
|
GetField(key string) (interface{}, bool)
|
||||||
HasField(key string) bool
|
HasField(key string) bool
|
||||||
RemoveField(key string)
|
RemoveField(key string)
|
||||||
|
Fields() map[string]interface{}
|
||||||
|
FieldList() []*lp.Field
|
||||||
|
String() string
|
||||||
|
SetTime(t time.Time)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (m *ccMetric) Meta() map[string]string {
|
func (m *ccMetric) Meta() map[string]string {
|
||||||
|
Loading…
Reference in New Issue
Block a user