Sha256: c41a8568914f3d18dbc96a7dd1c07efea828991b93b339f5d805ab97fbe14738

Contents?: true

Size: 565 Bytes

Versions: 14

Compression:

Stored size: 565 Bytes

Contents

require 'forwardable'

require 'honeybadger/backend/base'
require 'honeybadger/backend/server'
require 'honeybadger/backend/test'
require 'honeybadger/backend/null'
require 'honeybadger/backend/debug'

module Honeybadger
  module Backend
    class BackendError < StandardError; end

    def self.mapping
      @@mapping ||= {
        server: Server,
        test: Test,
        null: Null,
        debug: Debug
      }.freeze
    end

    def self.for(backend)
      mapping[backend] or raise(BackendError, "Unable to locate backend: #{backend}")
    end
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
honeybadger-3.2.0 lib/honeybadger/backend.rb
honeybadger-3.2.0.beta1 lib/honeybadger/backend.rb
honeybadger-3.1.2 lib/honeybadger/backend.rb
honeybadger-3.1.1 lib/honeybadger/backend.rb
honeybadger-3.1.0 lib/honeybadger/backend.rb
honeybadger-3.0.2 lib/honeybadger/backend.rb
honeybadger-3.0.1 lib/honeybadger/backend.rb
honeybadger-3.0.0 lib/honeybadger/backend.rb
honeybadger-3.0.0.beta6 lib/honeybadger/backend.rb
honeybadger-3.0.0.beta5 lib/honeybadger/backend.rb
honeybadger-3.0.0.beta4 lib/honeybadger/backend.rb
honeybadger-3.0.0.beta3 lib/honeybadger/backend.rb
honeybadger-3.0.0.beta2 lib/honeybadger/backend.rb
honeybadger-3.0.0.beta1 lib/honeybadger/backend.rb