Send an RPC notification over the network.
320318
async def send_notification(self, method, args=()):
        ''''''
        message = self.connection.send_notification(Notification(method, args))
        await self._send_message(message)
1250435
def send_ping(self, payload=''):
        
        self.send_frame(ControlFrame(OPCODE_PING, payload),
                        lambda: self.onping(payload))
        self.ping_payload = payload
        self.ping_sent = True
179579
def _send_msg(self, header, payload):
        """"""

        if self.verbose:
            print('->', repr(header))
            print('..', repr(payload))
        assert header.payload == len(payload)
        try:
            sent = self.socket.send(header + payload)
        except IOError as err:
            raise ConnError(*err.args)

        # FIXME FIXME FIXME:
        # investigate under which situations socket.send should be retried
        # instead of aborted.
        # FIXME FIXME FIXME
        if sent < len(header + payload):
            raise ShortWrite(sent, len(header + payload))
        assert sent == len(header + payload), sent
822818
async def send_frame(self, frame):
        """"""
        if not self.connection.connected:
            await self.connect()
            await self.update_version()
            await set_utc(pyvlx=self)
            await house_status_monitor_enable(pyvlx=self)
        self.connection.write(frame)
1163812
public static void sendNotification (
        ClientObject target, String receiverCode, int methodId, Object[] args)
    {
        sendNotification(target, receiverCode, methodId, args, Transport.DEFAULT);
    }
107276
def _notification(self, context, method, routers, operation,
                      shuffle_agents):
        """"""
        if extensions.is_extension_supported(self._l3plugin, L3AGENT_SCHED):
            adm_context = (context.is_admin and context or context.elevated())
            # This is where hosting device gets scheduled to Cisco cfg agent
            self._l3plugin.schedule_routers(adm_context, routers)
            self._agent_notification(
                context, method, routers, operation, shuffle_agents)
        else:
            cctxt = self.client.prepare(topics=topics.L3_AGENT, fanout=True)
            cctxt.cast(context, method, routers=[r['id'] for r in routers])
852206
def _notify(p, **data):
    """"""
    message = data.get("message")
    if not message and not sys.stdin.isatty():
        message = click.get_text_stream("stdin").read()
    data["message"] = message

    data = clean_data(data)

    ctx = click.get_current_context()
    if ctx.obj.get("env_prefix"):
        data["env_prefix"] = ctx.obj["env_prefix"]

    rsp = p.notify(**data)
    rsp.raise_on_errors()
    click.secho(f"Succesfully sent a notification to {p.name}!", fg="green")
1139251
def indication(self, pdu):
        """"""
        if _debug: TCPClientDirector._debug("indication %r", pdu)

        # get the destination
        addr = pdu.pduDestination

        # get the client
        client = self.clients.get(addr, None)
        if not client:
            client = self.actorClass(self, addr)

        # send the message
        client.indication(pdu)
989744
def send(self, msg):
        """"""
        self._router.broker.defer(self._send, msg)
806712
def send(self, fail_silently=False):
        """"""
        if not self.recipients():
            # Don't bother creating the network connection if
            # there's nobody to send to.
            return 0
        return self.get_connection(fail_silently).send_messages([self])
418696
def _send_ffe(self, pid, app_id, app_flags, fr):
        
        arg1 = (NNCommands.flood_fill_end << 24) | pid
        arg2 = (app_id << 24) | (app_flags << 18)
        self._send_scp(255, 255, 0, SCPCommands.nearest_neighbour_packet,
                       arg1, arg2, fr)
896218
def notify(self, method, params=None):
        
        log.debug('Sending notification: %s %s', method, params)

        message = {
            'jsonrpc': JSONRPC_VERSION,
            'method': method,
        }
        if params is not None:
            message['params'] = params

        self._consumer(message)
1296377
def on_recv_rsp(self, rsp_pb):
        """"""
        ret_code, msg, _= SubAccPush.unpack_rsp(rsp_pb)

        if self._notify_obj is not None:
            self._notify_obj.on_async_sub_acc_push(ret_code, msg)

        return ret_code, msg
751643
def send(self, message, level=Level.NOTICE):
    ""
    data = "<%d>%s" % (level + self.facility*8, message)
    if self.protocol == 'UDP':
        self.socket.sendto(data.encode('utf-8'), (self.host, self.port))
    else:
        self.socket.send(data.encode('utf-8'))
1331189
def send_message(client, message):
    """"""
    print(message)
    client.send("HTTP/1.1 200 OK\r\n\r\n{}".format(message).encode("utf-8"))
    client.close()
56749
def sendintr(self):
        ''' '''

        n, byte = self.ptyproc.sendintr()
        self._log_control(byte)
694675
def _send_script(self, device_info, control_info, script, progress_callback):
        

        for i in range(0, len(script), 20):
            chunk = script[i:i+20]
            self._send_rpc(device_info, control_info, 8, 0x2101, chunk, 0.001, 1.0)
            if progress_callback is not None:
                progress_callback(i + len(chunk), len(script))