Welcome to mirror list, hosted at ThFree Co, Russian Federation.

error.rb « delegator_override « utils « gitlab « lib - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: dfe8d5468b476ef1ec1ba8ad2f7c8515232a385e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# frozen_string_literal: true

module Gitlab
  module Utils
    module DelegatorOverride
      class Error
        attr_accessor :method_name, :target_class, :target_location, :delegator_class, :delegator_location

        def initialize(method_name, target_class, target_location, delegator_class, delegator_location)
          @method_name = method_name
          @target_class = target_class
          @target_location = target_location
          @delegator_class = delegator_class
          @delegator_location = delegator_location
        end

        def to_s
          "#{delegator_class}##{method_name} is overriding #{target_class}##{method_name}. delegator_location: #{delegator_location} target_location: #{target_location}"
        end
      end
    end
  end
end