aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/os/msgpack_rpc.h
diff options
context:
space:
mode:
authorThiago de Arruda <tpadilha84@gmail.com>2014-05-26 13:39:10 -0300
committerThiago de Arruda <tpadilha84@gmail.com>2014-05-26 14:02:12 -0300
commitf3dc04bf7f658f7d5d15047494fd15e286b4c7b6 (patch)
tree15a3471f10989c2877211447903fb9a2df66732f /src/nvim/os/msgpack_rpc.h
parent139c7ffdc785b19297e8c3b2d2586dfa284f97a5 (diff)
downloadrneovim-f3dc04bf7f658f7d5d15047494fd15e286b4c7b6.tar.gz
rneovim-f3dc04bf7f658f7d5d15047494fd15e286b4c7b6.tar.bz2
rneovim-f3dc04bf7f658f7d5d15047494fd15e286b4c7b6.zip
API: Events: Implement channel_send_event and vimscript wrapper
This function can be used to send arbitrary objects via the API channel back to connected clients, identified by channel id.
Diffstat (limited to 'src/nvim/os/msgpack_rpc.h')
-rw-r--r--src/nvim/os/msgpack_rpc.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/nvim/os/msgpack_rpc.h b/src/nvim/os/msgpack_rpc.h
index bc216c0856..319a069df7 100644
--- a/src/nvim/os/msgpack_rpc.h
+++ b/src/nvim/os/msgpack_rpc.h
@@ -16,6 +16,13 @@
/// @param res A packer that contains the response
void msgpack_rpc_call(uint64_t id, msgpack_object *req, msgpack_packer *res);
+/// Packs a notification message
+///
+/// @param type The message type, an arbitrary string
+/// @param data The notification data
+/// @param packer Where the notification will be packed to
+void msgpack_rpc_notification(String type, Object data, msgpack_packer *pac);
+
/// Dispatches to the actual API function after basic payload validation by
/// `msgpack_rpc_call`. It is responsible for validating/converting arguments
/// to C types, and converting the return value back to msgpack types.