Class: Rbcli::DeprecationWarning
- Inherits:
-
Object
- Object
- Rbcli::DeprecationWarning
- Defined in:
- lib/rbcli/util/deprecation_warning.rb
Constant Summary collapse
- @@warnings =
[]
Class Method Summary collapse
Instance Method Summary collapse
- #display ⇒ Object
-
#initialize(original_feature_name, message_text, change_by_version) ⇒ DeprecationWarning
constructor
A new instance of DeprecationWarning.
Constructor Details
#initialize(original_feature_name, message_text, change_by_version) ⇒ DeprecationWarning
Returns a new instance of DeprecationWarning.
26 27 28 29 30 31 32 |
# File 'lib/rbcli/util/deprecation_warning.rb', line 26 def initialize original_feature_name, , change_by_version #@caller = caller_locations(2,1)[0].label @original_feature_name = original_feature_name @message_text = @change_by_version = change_by_version @@warnings.append self end |
Class Method Details
.display_warnings ⇒ Object
40 41 42 |
# File 'lib/rbcli/util/deprecation_warning.rb', line 40 def self.display_warnings @@warnings.each { |w| w.display } end |