From b1ad04330bfbf0e45531531b999e2f97aa4fd7f5 Mon Sep 17 00:00:00 2001 From: David Wilson Date: Sat, 7 Oct 2017 16:59:16 +0530 Subject: [PATCH] docs: move Router.route() into Sphinx. --- docs/api.rst | 8 +++++--- mitogen/core.py | 7 ------- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/docs/api.rst b/docs/api.rst index 5a7b12ed..5f91cd83 100644 --- a/docs/api.rst +++ b/docs/api.rst @@ -340,9 +340,11 @@ Router Class .. method:: route(msg) - Arrange for `msg` to be forwarded towards its destination. If its - destination is the local context, then arrange for it to be dispatched - using the local handlers. + Arrange for the :py:class:`Message` `msg` to be delivered to its + destination using any relevant downstream context, or if none is found, + by forwarding the message upstream towards the master context. If `msg` + is destined for the local context, it is dispatched using the handles + registered with :py:meth:`add_handler`. This may be called from any thread. diff --git a/mitogen/core.py b/mitogen/core.py index ed49044d..6cf5a0b8 100644 --- a/mitogen/core.py +++ b/mitogen/core.py @@ -914,13 +914,6 @@ class Router(object): stream.send(msg) def route(self, msg): - """ - Arrange for the :py:class:`Message` `msg` to be delivered to its - destination using any relevant downstream context, or if none is found, - by forwarding the message upstream towards the master context. If `msg` - is destined for the local context, it is dispatched using the handles - registered with :py:meth:`add_handler`. - """ self.broker.defer(self._async_route, msg)