Sha256: c26ed7bd081405271f0f8b00e597cd6f5b42c0042b8fb925a5721d9997c8e966

Contents?: true

Size: 444 Bytes

Versions: 1

Compression:

Stored size: 444 Bytes

Contents

# frozen_string_literal: true

require 'active_support/concern'

module LibvirtAsync
  module WithDbg
    extend ActiveSupport::Concern

    class_methods do
      def dbg(progname = nil, &block)
        LibvirtAsync.logger&.debug(progname || "0x#{object_id.to_s(16)}", &block)
      end
    end

    private

    def dbg(progname = nil, &block)
      LibvirtAsync.logger&.debug(progname || "0x#{object_id.to_s(16)}", &block)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
libvirt_async-0.4.0 lib/libvirt_async/with_dbg.rb