// Metrics returns the collected metrics.
Metrics returns the collected metrics.
// Metrics returns the collected metrics .
func (p *MultiProfiler) Metrics() Metrics {
	results := make([]Result, 0, len(p.profilers))
	var elapsed time.Duration
	for _, prof := range p.profilers {
		metrics := prof.Metrics()
		results = append(results, metrics.Results...)
		elapsed = metrics.Elapsed
	}
	return Metrics{
		Results: results,
		Elapsed: elapsed,
	}
}
func ( p * MultiProfiler ) Metrics ( ) Metrics { results := make ( [ ] Result , 0 , len ( p . profilers ) ) var elapsed time . Duration for _ , prof := range p . profilers { metrics := prof . Metrics ( ) results = append ( results , metrics . Results ... ) elapsed = metrics . Elapsed } return Metrics { Results : results , Elapsed : elapsed , } }
Metrics returns the collected metrics.
Metrics returns the collected metrics .