lib/micro_bench.rb
# Give duration of the benchmark
#
# == Parameters:
# bench_id::
#   Identifier of the benchmark
#
# == Returns:
# Formatted duration of the given benchmark, or nil if benchmark is unknown.
#
# == Example usage:
#   MicroBench.duration(:my_benchmark)
#
Give duration of the benchmark
Parameters:
bench_id::
Identifier of the benchmark

Formatted duration of the given benchmark, or nil if benchmark is unknown.


Give duration of the benchmark Parameters : bench_id :: Identifier of the benchmark Formatted duration of the given benchmark or nil if benchmark is unknown .
def duration(bench_id = nil)
      raw = raw_duration(bench_id)
      return nil if raw.nil?
      configurations.formatter.call(raw)
    end
def duration ( bench_id = nil ) raw = raw_duration ( bench_id ) return nil if raw . nil? configurations . formatter . call ( raw ) end
Give duration of the benchmark
 Parameters:
bench_id::
Identifier of the benchmark
Give duration of the benchmark Parameters : bench_id :: Identifier of the benchmark
bench_id
<not_specific>