diff options
| author | Dag-Erling Smørgrav <des@FreeBSD.org> | 2017-02-03 13:06:34 +0000 |
|---|---|---|
| committer | Dag-Erling Smørgrav <des@FreeBSD.org> | 2017-02-03 13:06:34 +0000 |
| commit | bd51c20871bac7a49ea0adc443050f2894cfd5f3 (patch) | |
| tree | c551994131aa8f3315a21aeaf4f9bc2a8b757e89 /libunbound/python/doc/examples/example3.rst | |
| parent | 27c2fff0f2fef695b0599fc3931cacfc16376e88 (diff) | |
Diffstat (limited to 'libunbound/python/doc/examples/example3.rst')
| -rw-r--r-- | libunbound/python/doc/examples/example3.rst | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/libunbound/python/doc/examples/example3.rst b/libunbound/python/doc/examples/example3.rst index 91360335c63a..b0626b55f9c1 100644 --- a/libunbound/python/doc/examples/example3.rst +++ b/libunbound/python/doc/examples/example3.rst @@ -1,12 +1,14 @@ .. _example_asynch: -============================== Asynchronous lookup -============================== +=================== This example performs the name lookup in the background. The main program keeps running while the name is resolved. +Source code +----------- + :: #!/usr/bin/python @@ -33,4 +35,5 @@ The main program keeps running while the name is resolved. if (status != 0): print "Resolve error:", unbound.ub_strerror(status) -The :meth:`unbound.ub_ctx.resolve_async` method is able to pass on any Python object. In this example, we used a dictionary object `my_data`. +The :meth:`unbound.ub_ctx.resolve_async` method is able to pass on any Python +object. In this example, we used a dictionary object ``my_data``. |
