Exception: Batchwatch::HTTPError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/batchwatch/client.rb

Overview

A non-2xx response. Never reaches the caller of a public method - only the optional debug logger.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(status, body) ⇒ HTTPError

Returns a new instance of HTTPError.



211
212
213
214
215
# File 'lib/batchwatch/client.rb', line 211

def initialize(status, body)
  @status = status
  @body = body
  super("batchwatch #{status}")
end

Instance Attribute Details

#bodyObject (readonly)

Returns the value of attribute body.



209
210
211
# File 'lib/batchwatch/client.rb', line 209

def body
  @body
end

#statusObject (readonly)

Returns the value of attribute status.



209
210
211
# File 'lib/batchwatch/client.rb', line 209

def status
  @status
end