summaryrefslogtreecommitdiff
path: root/src/core/protocol.h
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2017-10-20 17:03:12 -0700
committerGarrett D'Amore <garrett@damore.org>2017-10-23 16:14:53 -0700
commit3585000ca027740dbdb4599f4991cd2bf562e2f2 (patch)
treea45b4c1bcc2d11777dde0e38d4b742d121d55e45 /src/core/protocol.h
parentfdb73b69a887d868f8e976ef8a990a5d7f6687f9 (diff)
downloadnng-3585000ca027740dbdb4599f4991cd2bf562e2f2.tar.gz
nng-3585000ca027740dbdb4599f4991cd2bf562e2f2.tar.bz2
nng-3585000ca027740dbdb4599f4991cd2bf562e2f2.zip
fixes #112 Need to move some stuff from socket to message queues
Diffstat (limited to 'src/core/protocol.h')
-rw-r--r--src/core/protocol.h16
1 files changed, 9 insertions, 7 deletions
diff --git a/src/core/protocol.h b/src/core/protocol.h
index 0c0d93ce..253452d8 100644
--- a/src/core/protocol.h
+++ b/src/core/protocol.h
@@ -74,15 +74,17 @@ struct nni_proto_sock_ops {
// it can signal the socket worker threads to exit.
void (*sock_close)(void *);
- // Receive filter. This may be NULL, but if it isn't, then
+ // Send a message.
+ void (*sock_send)(void *, nni_aio *);
+
+ // Receive a message.
+ void (*sock_recv)(void *, nni_aio *);
+
+ // Message filter. This may be NULL, but if it isn't, then
// messages coming into the system are routed here just before being
- // delivered to the application. To drop the message, the prtocol
+ // delivered to the application. To drop the message, the protocol
// should return NULL, otherwise the message (possibly modified).
- nni_msg *(*sock_rfilter)(void *, nni_msg *);
-
- // Send filter. This may be NULL, but if it isn't, then messages
- // here are filtered just after they come from the application.
- nni_msg *(*sock_sfilter)(void *, nni_msg *);
+ nni_msg *(*sock_filter)(void *, nni_msg *);
// Options. Must not be NULL. Final entry should have NULL name.
nni_proto_sock_option *sock_options;