Exception: UCEngine::Client::HttpError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/em-ucengine/errors.rb

Direct Known Subclasses

UCError

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(code, description, uri = nil) ⇒ HttpError

Returns a new instance of HttpError.



6
7
8
9
10
# File 'lib/em-ucengine/errors.rb', line 6

def initialize code, description, uri=nil
  @code = code
  @description = description
  @uri = uri
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



4
5
6
# File 'lib/em-ucengine/errors.rb', line 4

def code
  @code
end

#descriptionObject (readonly)

Returns the value of attribute description.



4
5
6
# File 'lib/em-ucengine/errors.rb', line 4

def description
  @description
end

#uriObject (readonly)

Returns the value of attribute uri.



4
5
6
# File 'lib/em-ucengine/errors.rb', line 4

def uri
  @uri
end

Instance Method Details

#to_sObject



12
13
14
# File 'lib/em-ucengine/errors.rb', line 12

def to_s
  "<#{self.class.name} ##{@code} \"#{@description}\" #{@uri}>"
end