Sha256: 869b4cdfa8c27d0f70e5465a0817dbe863f47ee40f7fd03d2c0ef835dbb89e6c
Contents?: true
Size: 621 Bytes
Versions: 19
Compression:
Stored size: 621 Bytes
Contents
module ZTK class Profiler # Profiler Timer Functionality class Timer require 'ztk/profiler/timer/class_methods' extend ZTK::Profiler::Timer::ClassMethods attr_accessor :name attr_accessor :parent attr_accessor :benchmark def initialize(name, parent=nil) self.name = name self.parent = parent self.class.add(self) end def nested_time @nested_time ||= self.class.nested_time(self.name, self) @nested_time end def benchmark_nested (self.benchmark - self.nested_time) end end end end
Version data entries
19 entries across 19 versions & 1 rubygems