Module: EAAL::Exception
- Defined in:
- lib/eaal/exception.rb
Overview
– EAAL by Peter Petermann <[email protected]> This library is licensed under the terms found in the LICENSE file distributed with it ++
Defined Under Namespace
Classes: APINotFoundError, EAALError, EveAPIException, HTTPError
Class Method Summary collapse
-
.EveAPIException(nr) ⇒ Object
creates the class for an EveAPIException.
-
.raiseEveAPIException(nr, msg) ⇒ Object
raise the eve API exceptions, class will be dynamicaly created by classname EveAPIException followed by the APIs exception Number.
Class Method Details
.EveAPIException(nr) ⇒ Object
creates the class for an EveAPIException
8 9 10 11 12 13 14 15 16 |
# File 'lib/eaal/exception.rb', line 8 def self.EveAPIException(nr) classname = "EveAPIException#{nr}" if not Object.const_defined? classname klass = Object.const_set(classname, Class.new(EAAL::Exception::EveAPIException)) else klass = Object.const_get(classname) end klass end |
.raiseEveAPIException(nr, msg) ⇒ Object
raise the eve API exceptions, class will be dynamicaly created by classname EveAPIException followed by the APIs exception Number
20 21 22 |
# File 'lib/eaal/exception.rb', line 20 def self.raiseEveAPIException(nr, msg) raise EAAL::Exception.EveAPIException(nr).new(msg) end |