Class: Nanoc::Core::Instrumentor Private
- Inherits:
-
Object
- Object
- Nanoc::Core::Instrumentor
- Defined in:
- lib/nanoc/core/instrumentor.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Class Method Summary collapse
- .call(key, *args) ⇒ Object private
Class Method Details
.call(key, *args) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
7 8 9 10 11 12 13 14 |
# File 'lib/nanoc/core/instrumentor.rb', line 7 def self.call(key, *args) stopwatch = DDMetrics::Stopwatch.new stopwatch.start yield ensure stopwatch.stop Nanoc::Core::NotificationCenter.post(key, stopwatch.duration, *args) end |