Package csb :: Package apps :: Class AppExit

[frames] | no frames]

# Class AppExit

source code

                  object --+
                           |
    exceptions.BaseException --+
                               |
            exceptions.Exception --+
                                   |
                                  AppExit

Used to signal an immediate application exit condition (e.g. a fatal error), that propagates down to the client, instead of forcing the interpreter to close via `sys.exit()`.

Instance Methods

__init__(self, message=`'````'`, code=0, usage=False) x.__init__(...) initializes x; see help(type(x)) for signature | source code

Inherited from `exceptions.Exception`: `__new__` Inherited from `exceptions.BaseException`: `__delattr__`, `__getattribute__`, `__getitem__`, `__getslice__`, `__reduce__`, `__repr__`, `__setattr__`, `__setstate__`, `__str__`, `__unicode__` Inherited from `object`: `__format__`, `__hash__`, `__reduce_ex__`, `__sizeof__`, `__subclasshook__`

Properties
Inherited from `exceptions.BaseException`: `args`, `message` Inherited from `object`: `__class__`

Method Details

### __init__(self, message=`'````'`, code=0, usage=False)
(Constructor)

source code

x.__init__(...) initializes x; see help(type(x)) for signature

Parameters:
  - `message` (str) - exit message
  - `code` (int) - exit code (see ExitCodes for common constants)
  - `usage` (bool) - ask the app runner to print also the app's usage line
Overrides: object.__init__
  (inherited documentation)