Exception: HawatelPS::Windows::WmiCliException
- Inherits:
-
Exception
- Object
- Exception
- HawatelPS::Windows::WmiCliException
- Defined in:
- lib/hawatel_ps/windows/wmi/wmi_exception.rb
Instance Method Summary collapse
- #exception_enrichment(args) ⇒ Object private
-
#initialize(args = {:exception => nil, :message => nil}) ⇒ void
constructor
Custom exception.
Constructor Details
#initialize(args = {:exception => nil, :message => nil}) ⇒ void
Custom exception
9 10 11 |
# File 'lib/hawatel_ps/windows/wmi/wmi_exception.rb', line 9 def initialize(args = {:exception => nil, :message => nil}) super(exception_enrichment(args)) end |
Instance Method Details
#exception_enrichment(args) ⇒ Object (private)
14 15 16 17 18 19 20 |
# File 'lib/hawatel_ps/windows/wmi/wmi_exception.rb', line 14 def exception_enrichment(args) = '' += args[:message] unless args[:message].nil? += "\nNative exception from '#{args[:exception].class}':\n#{args[:exception].}" unless args[:exception].nil? return end |