aboutsummaryrefslogtreecommitdiff
path: root/docs/nng_sub.adoc
diff options
context:
space:
mode:
Diffstat (limited to 'docs/nng_sub.adoc')
-rw-r--r--docs/nng_sub.adoc53
1 files changed, 19 insertions, 34 deletions
diff --git a/docs/nng_sub.adoc b/docs/nng_sub.adoc
index bae52b4f..cbb4fe51 100644
--- a/docs/nng_sub.adoc
+++ b/docs/nng_sub.adoc
@@ -1,23 +1,18 @@
-nng_sub(7)
-==========
+= nng_sub(7)
:doctype: manpage
:manmanual: nng
:mansource: nng
-:icons: font
-:source-highlighter: pygments
-:copyright: Copyright 2018 Garrett D'Amore <garrett@damore.org> \
- Copyright 2018 Capitar IT Group BV <info@capitar.com> \
- This software is supplied under the terms of the MIT License, a \
- copy of which should be located in the distribution where this \
- file was obtained (LICENSE.txt). A copy of the license may also \
- be found online at https://opensource.org/licenses/MIT.
-
-NAME
-----
+:copyright: Copyright 2018 mailto:info@staysail.tech[Staysail Systems, Inc.] + \
+ Copyright 2018 mailto:info@capitar.com[Capitar IT Group BV] + \
+ {blank} + \
+ This document is supplied under the terms of the \
+ https://opensource.org/licenses/MIT[MIT License].
+
+== NAME
+
nng_sub - subscriber protocol
-SYNOPSIS
---------
+== SYNOPSIS
[source,c]
----------
@@ -26,8 +21,7 @@ SYNOPSIS
int nng_sub0_open(nng_socket *s);
----------
-DESCRIPTION
------------
+== DESCRIPTION
The _nng_sub_ protocol is one half of a publisher/subscriber pattern.
In this pattern, a publisher sends data, which is broadcast to all
@@ -46,21 +40,18 @@ The topics that subscribers subscribe to is just the first part of
the message body. Applications should construct their messages
accordingly.
-Socket Operations
-~~~~~~~~~~~~~~~~~
+=== Socket Operations
The `nng_sub0_open()` call creates a subscriber socket. This socket
may be used to receive messages, but is unable to send them. Attempts
to send messages will result in `NNG_ENOTSUP`.
-Protocol Versions
-~~~~~~~~~~~~~~~~~
+=== Protocol Versions
Only version 0 of this protocol is supported. (At the time of writing,
no other versions of this protocol have been defined.)
-Protocol Options
-~~~~~~~~~~~~~~~~
+=== Protocol Options
The following protocol-specific options are available.
@@ -81,21 +72,15 @@ TIP: To receive all messages, an empty topic (zero length) can be used.
Note that if the topic was not previously subscribed to with
`NNG_OPT_SUB_SUBSCRIBE` then an `NNG_ENOENT` error will result.
-Protocol Headers
-~~~~~~~~~~~~~~~~
+=== Protocol Headers
The _nng_sub_ protocol has no protocol-specific headers.
-SEE ALSO
---------
+== SEE ALSO
+
<<nng#,nng(7)>>,
<<nng_pub#,nng_pub(7)>>
-COPYRIGHT
----------
-
-Copyright 2018 mailto:garrett@damore.org[Garrett D'Amore] +
-Copyright 2018 mailto:info@capitar.com[Capitar IT Group BV]
+== COPYRIGHT
-This document is supplied under the terms of the
-https://opensource.org/licenses/MIT[MIT License].
+{copyright} \ No newline at end of file