Sha256: c4f6b53d0f90ad79d39d3dfc9dfb15bb05c8acd0387ab0af54bdac243cb91bcb
Contents?: true
Size: 447 Bytes
Versions: 10
Compression:
Stored size: 447 Bytes
Contents
# encoding: utf-8 module Hyperdrive module Instrumenters class Memory Event = Struct.new(:name, :payload, :result) attr_reader :events def initialize @events = [] end def instrument(name, payload = {}) result = if block_given? yield payload else payload end @events << Event.new(name, payload, result) result end end end end
Version data entries
10 entries across 10 versions & 1 rubygems