Adds hander for specified message.

        :param str message:
            Name of message to subscribe to.

        :param callable handler:
            Handler for this message type. Handler must receive single parameter
            and that parameter will be instance of sent message.

def subscribe(self, message, handler):
        '''
        Adds hander for specified message.

        :param str message:
            Name of message to subscribe to.

        :param callable handler:
            Handler for this message type. Handler must receive single parameter
            and that parameter will be instance of sent message.
        '''
        with self._lock:
            ref = WeakCallable(handler, self._on_collect)
            self._subscribers[message].append(ref)