debian-mirror-gitlab/lib/gitlab/utils/delegator_override/error.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

24 lines
776 B
Ruby
Raw Normal View History

2021-11-18 22:05:49 +05:30
# 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