Exception: TaboolaApi::Error

Inherits:
StandardError
  • Object
show all
Defined in:
lib/taboola_api/error.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message = nil, status_code = nil, body = nil) ⇒ Error

Returns a new instance of Error.



6
7
8
9
10
# File 'lib/taboola_api/error.rb', line 6

def initialize(message = nil, status_code = nil, body = nil)
  @status_code = status_code
  @body = body
  super(message)
end

Instance Attribute Details

#bodyObject (readonly)

Returns the value of attribute body.



4
5
6
# File 'lib/taboola_api/error.rb', line 4

def body
  @body
end

#status_codeObject (readonly)

Returns the value of attribute status_code.



3
4
5
# File 'lib/taboola_api/error.rb', line 3

def status_code
  @status_code
end