def send_message(self, data, inc_session_id=False,
                     callback_function=None):
        """
        Send a message on this namespace to the Chromecast.

        Will raise a NotConnected exception if not connected.
        """
        self._check_registered()

        if not self.target_platform and \
           self.namespace not in self._socket_client.app_namespaces:
            if self.supporting_app_id is not None:
                self.launch()

            else:
                raise UnsupportedNamespace(
                    ("Namespace {} is not supported by running"
                     "application.").format(self.namespace))

        return self._message_func(
            self.namespace, data, inc_session_id, callback_function)
Send a message on this namespace to the Chromecast.

        Will raise a NotConnected exception if not connected.