Documentation ¶
Index ¶
- type Counter
- type CounterMetric
- type DateCounter
- type GaugeMetric
- type HistogramMetric
- type StandardCounter
- type StandardDateCounter
- func (c *StandardDateCounter) Clear()
- func (c *StandardDateCounter) Dec(count int64)
- func (c *StandardDateCounter) GetLastDaysCount(lastdays int64) []int64
- func (c *StandardDateCounter) Inc(count int64)
- func (c *StandardDateCounter) Snapshot() DateCounter
- func (c *StandardDateCounter) TodayCount() int64
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Counter ¶
func NewCounter ¶
func NewCounter() Counter
type CounterMetric ¶ added in v0.32.0
type CounterMetric interface {
Inc()
}
CounterMetric represents a single numerical value that only ever goes up.
type DateCounter ¶
type DateCounter interface { TodayCount() int64 GetLastDaysCount(lastdays int64) []int64 Inc(int64) Dec(int64) Snapshot() DateCounter Clear() }
func NewDateCounter ¶
func NewDateCounter(reserveDays int64) DateCounter
type GaugeMetric ¶ added in v0.32.0
type GaugeMetric interface { Inc() Dec() Set(float64) }
GaugeMetric represents a single numerical value that can arbitrarily go up and down.
type HistogramMetric ¶ added in v0.32.0
type HistogramMetric interface {
Observe(float64)
}
HistogramMetric counts individual observations.
type StandardCounter ¶
type StandardCounter struct {
// contains filtered or unexported fields
}
func (*StandardCounter) Clear ¶
func (c *StandardCounter) Clear()
func (*StandardCounter) Count ¶
func (c *StandardCounter) Count() int32
func (*StandardCounter) Dec ¶
func (c *StandardCounter) Dec(count int32)
func (*StandardCounter) Inc ¶
func (c *StandardCounter) Inc(count int32)
func (*StandardCounter) Snapshot ¶
func (c *StandardCounter) Snapshot() Counter
type StandardDateCounter ¶
type StandardDateCounter struct {
// contains filtered or unexported fields
}
func (*StandardDateCounter) Clear ¶
func (c *StandardDateCounter) Clear()
func (*StandardDateCounter) Dec ¶
func (c *StandardDateCounter) Dec(count int64)
func (*StandardDateCounter) GetLastDaysCount ¶
func (c *StandardDateCounter) GetLastDaysCount(lastdays int64) []int64
func (*StandardDateCounter) Inc ¶
func (c *StandardDateCounter) Inc(count int64)
func (*StandardDateCounter) Snapshot ¶
func (c *StandardDateCounter) Snapshot() DateCounter
func (*StandardDateCounter) TodayCount ¶
func (c *StandardDateCounter) TodayCount() int64
Click to show internal directories.
Click to hide internal directories.