Documentation ¶
Overview ¶
Package metrics contains metrics models, constants and formatting.
Index ¶
Constants ¶
View Source
const ( // Nano is the time scale in nanoseconds. Nano TimeScale = "ns" // Micro is the time scale in microseconds. Micro TimeScale = "μs" // Milli is the time scale in milliseconds. Milli TimeScale = "ms" // Byte is the size scale in bytes. Byte SizeScale = "b" // KiloByte is the size scale in kilobytes. KiloByte SizeScale = "Kb" // MegaByte is the size scale in megabytes. MegaByte SizeScale = "Mb" // GigaByte is the size scale in gigabytes. GigaByte SizeScale = "Gb" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Report ¶
type Report struct { TimeMetrics []TimeMetric SizeMetric SizeMetric }
Report is a metrics report.
type SizeMetric ¶
SizeMetric is a size metric.
func (*SizeMetric) Normalize ¶
func (s *SizeMetric) Normalize()
Normalize normalizes the size metric.
func (*SizeMetric) String ¶
func (s *SizeMetric) String() string
String returns the size metric formatted.
type TimeMetric ¶
TimeMetric is a time metric.
func (*TimeMetric) Normalize ¶
func (m *TimeMetric) Normalize()
Normalize normalizes the time metric.
func (*TimeMetric) String ¶
func (m *TimeMetric) String() string
String returns the time metric formatted.
Click to show internal directories.
Click to hide internal directories.