metrics.mx raw

   1  // Package metrics is a dummy package that is not yet implemented.
   2  
   3  package metrics
   4  
   5  type Description struct {
   6  	Name        string
   7  	Description string
   8  	Kind        ValueKind
   9  	Cumulative  bool
  10  }
  11  
  12  func All() []Description {
  13  	return nil
  14  }
  15  
  16  type Float64Histogram struct {
  17  	Counts  []uint64
  18  	Buckets []float64
  19  }
  20  
  21  type Sample struct {
  22  	Name  string
  23  	Value Value
  24  }
  25  
  26  func Read(m []Sample) {}
  27  
  28  type Value struct{}
  29  
  30  func (v Value) Float64() float64 {
  31  	return 0
  32  }
  33  func (v Value) Float64Histogram() *Float64Histogram {
  34  	return nil
  35  }
  36  func (v Value) Kind() ValueKind {
  37  	return KindBad
  38  }
  39  func (v Value) Uint64() uint64 {
  40  	return 0
  41  }
  42  
  43  type ValueKind int
  44  
  45  const (
  46  	KindBad ValueKind = iota
  47  	KindUint64
  48  	KindFloat64
  49  	KindFloat64Histogram
  50  )
  51