Exception: Figo::Error

Inherits:
RuntimeError
  • Object
show all
Defined in:
lib/helpers/error.rb

Overview

Base class for all errors transported via the figo Connect API.

Instance Method Summary collapse

Constructor Details

#initialize(error, error_description) ⇒ Error

Initialize error object.

Parameters:

  • error (String)

    the error code

  • error_description (String)

    the error description



8
9
10
11
# File 'lib/helpers/error.rb', line 8

def initialize(error, error_description)
  @error = error
  @error_description = error_description
end

Instance Method Details

#to_sString

Convert error object to string.

Returns:

  • (String)

    the error description



16
17
18
# File 'lib/helpers/error.rb', line 16

def to_s
  return @error_description
end