// Metrics returns the collected metrics.
Metrics returns the collected metrics.
// Metrics returns the collected metrics .
func (p *SingleProfiler) Metrics() Metrics {
	c, _ := p.ReadCount()
	if c.Enabled != c.Running {
		logger.Printf("%s: multiplexing occurred (enabled: %s, running %s)\n", c.Label, c.Enabled, c.Running)
	}
	return Metrics{
		Results: []Result{
			{
				Value: uint64(float64(c.Value) * float64(c.Enabled) / float64(c.Running)),
				Label: c.Label,
			},
		},
		Elapsed: c.Enabled - p.enabled,
	}
}
func ( p * SingleProfiler ) Metrics ( ) Metrics { c , _ := p . ReadCount ( ) if c . Enabled != c . Running { logger . Printf ( " \n " , c . Label , c . Enabled , c . Running ) } return Metrics { Results : [ ] Result { { Value : uint64 ( float64 ( c . Value ) * float64 ( c . Enabled ) / float64 ( c . Running ) ) , Label : c . Label , } , } , Elapsed : c . Enabled - p . enabled , } }
Metrics returns the collected metrics.
Metrics returns the collected metrics .