File: interfaces.rst

package info (click to toggle)
kazoo 1.3.1-1
  • links: PTS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 860 kB
  • ctags: 1,246
  • sloc: python: 8,192; makefile: 197
file content (33 lines) | stat: -rw-r--r-- 1,007 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
.. _interfaces_module:

:mod:`kazoo.interfaces`
----------------------------

.. automodule:: kazoo.interfaces

Public API
++++++++++

:class:`IHandler` implementations should be created by the developer to be
passed into :class:`~kazoo.client.KazooClient` during instantiation for the
preferred callback handling.

If the developer needs to use objects implementing the :class:`IAsyncResult`
interface, the :meth:`IHandler.async_result` method must be used instead of
instantiating one directly.

    .. autointerface:: IHandler
     :members:

Private API
+++++++++++

The :class:`IAsyncResult` documents the proper implementation for providing
a value that results from a Zookeeper completion callback. Since the
:class:`~kazoo.client.KazooClient` returns an :class:`IAsyncResult` object
instead of taking a completion callback for async functions, developers
wishing to have their own callback called should use the
:meth:`IAsyncResult.rawlink` method.

  .. autointerface:: IAsyncResult
     :members: