Exception: ConnectorsShared::MonitoringError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/connectors_shared/errors.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message = nil, tripped_by: nil) ⇒ MonitoringError

Returns a new instance of MonitoringError.



63
64
65
66
# File 'lib/connectors_shared/errors.rb', line 63

def initialize(message = nil, tripped_by: nil)
  super("#{message}#{tripped_by.present? ? " Tripped by - #{tripped_by.class}: #{tripped_by.message}" : ''}")
  @tripped_by = tripped_by
end

Instance Attribute Details

#tripped_byObject

Returns the value of attribute tripped_by.



61
62
63
# File 'lib/connectors_shared/errors.rb', line 61

def tripped_by
  @tripped_by
end