Package coro :: Module _coro :: Class aio_control_block
[hide private]
[frames] | no frames]

Class aio_control_block

object --+
         |
        aio_control_block

Wrapper for 'struct aiocb'. This structure holds important information in place for the kernel while it performs I/O asynchronously.
Instance Methods [hide private]
 
__init__(...)
x.__init__(...) initializes x; see help(type(x)) for signature
a new object with type S, a subtype of T
__new__(T, S, ...)
 
__repr__(x)
repr(x)
 
abort_cleanup(...)
Cleanup AIO data structure after an abort.

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __reduce__, __reduce_ex__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(...)
(Constructor)

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

__new__(T, S, ...)

 
Returns: a new object with type S, a subtype of T
Overrides: object.__new__

__repr__(x)
(Representation operator)

 
repr(x)
Overrides: object.__repr__

abort_cleanup(...)

 

Cleanup AIO data structure after an abort.

If an AIO request is aborted (such as with coro.Interrupted), the kevent is still going to eventually fire. So we change the target of the kevent to be this function instead of the coroutine to do cleanup and avoid scheduling the coroutine twice.