Exception: Appwrite::Exception

Inherits:
StandardError
  • Object
show all
Defined in:
lib/appwrite/exception.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, code = 0, type = nil, response = nil) ⇒ Exception

Returns a new instance of Exception.



7
8
9
10
11
12
# File 'lib/appwrite/exception.rb', line 7

def initialize(message, code = 0, type = nil, response = nil)
    super(message)
    @code = code
    @type = type
    @response = response
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



3
4
5
# File 'lib/appwrite/exception.rb', line 3

def code
  @code
end

#responseObject (readonly)

Returns the value of attribute response.



4
5
6
# File 'lib/appwrite/exception.rb', line 4

def response
  @response
end

#typeObject (readonly)

Returns the value of attribute type.



5
6
7
# File 'lib/appwrite/exception.rb', line 5

def type
  @type
end