Sha256: 3cbdb5a151ba9ebd96780b748664c42287803afd526ca4c598c851cca672c64d

Contents?: true

Size: 734 Bytes

Versions: 38

Compression:

Stored size: 734 Bytes

Contents

module Timber
  module Contexts
    # Tracks OS level process information, such as the process ID.
    class Runtime < Context
      @keyspace = :runtime

      attr_reader :application, :class_name, :file, :function, :line, :module_name

      def initialize(attributes)
        @application = attributes[:application]
        @class_name = attributes[:class_name]
        @file = attributes[:file]
        @function = attributes[:function]
        @line = attributes[:line]
        @module_name = attributes[:module_name]
      end

      def as_json(_options = {})
        {application: application, class_name: class_name, file: file, function: function,
          line: line, module_name: module_name}
      end
    end
  end
end

Version data entries

38 entries across 38 versions & 1 rubygems

Version Path
timber-2.0.2 lib/timber/contexts/runtime.rb
timber-2.0.1 lib/timber/contexts/runtime.rb
timber-2.0.0 lib/timber/contexts/runtime.rb
timber-1.1.14 lib/timber/contexts/runtime.rb
timber-1.1.13 lib/timber/contexts/runtime.rb
timber-1.1.12 lib/timber/contexts/runtime.rb
timber-1.1.11 lib/timber/contexts/runtime.rb
timber-1.1.10 lib/timber/contexts/runtime.rb
timber-1.1.9 lib/timber/contexts/runtime.rb
timber-1.1.8 lib/timber/contexts/runtime.rb
timber-1.1.7 lib/timber/contexts/runtime.rb
timber-1.1.6 lib/timber/contexts/runtime.rb
timber-1.1.5 lib/timber/contexts/runtime.rb
timber-1.1.4 lib/timber/contexts/runtime.rb
timber-1.1.3 lib/timber/contexts/runtime.rb
timber-1.1.2 lib/timber/contexts/runtime.rb
timber-1.1.1 lib/timber/contexts/runtime.rb
timber-1.1.0 lib/timber/contexts/runtime.rb