Publish a CommandSucceededEvent.
350595
def _succeed(self, request_id, reply, duration):
        """"""
        self.listeners.publish_command_success(
            duration, reply, self.name,
            request_id, self.sock_info.address, self.op_id)
824721
def OnSecondaryCheckbox(self, event):
        """"""

        self.attrs["top"] = event.IsChecked()
        self.attrs["right"] = event.IsChecked()

        post_command_event(self, self.DrawChartMsg)
1060895
protected void publishResourceEvent(
            IPortletWindow portletWindow,
            HttpServletRequest httpServletRequest,
            long executionTime,
            boolean usedBrowserCache,
            boolean usedPortalCache) {

        final IPortletWindowId portletWindowId = portletWindow.getPortletWindowId();

        this.portalEventFactory.publishPortletResourceExecutionEvent(
                httpServletRequest,
                this,
                portletWindowId,
                executionTime,
                usedBrowserCache,
                usedPortalCache);
    }
1246128
function(cmdPointer, next) {

                                        // Publish it now...
                                        commandDispatcher.dispatch(cmdPointer.command, function(err) {
                                            if (cmdPointer.callback) cmdPointer.callback(null);
                                            next();
                                        });
                                    }
546904
private void onMessageDelivered(MessageDeliveredEvent event) {
        handler.post(() -> listener.onMessageDelivered(event));
        log("Event published " + event.toString());
    }
412202
def _dispatch_event(self, event: LutronEvent, params: Dict):
    """"""
    for handler, context in self._subscribers:
      handler(self, context, event, params)
1295858
def command_publish(self, command, **kwargs):
        
        mqttc = mqtt.Client()
        mqttc.connect(
            command['host'],
            port=int(command['port']))

        mqttc.loop_start()

        try:
            mqttc.publish(
                command['endpoint'],
                command['payload'])
        finally:
            mqttc.loop_stop(force=False)
560581
private void publishEvent(WSJobInstance objectToPublish, String eventToPublish) {

        if (getBatchEventsPublisher() != null) {
            getBatchEventsPublisher().publishJobInstanceEvent(objectToPublish, eventToPublish, correlationId);
        }
    }
444301
public void publish(Object event) {
        Objects.requireNonNull(event, Required.EVENT.toString());
        
        this.eventBus.post(event);
        this.events.getAndIncrement();
    }
337774
private void publishEvent(WSJobInstance jobInst, String topicToPublish, String correlationId) {
        if (eventsPublisher != null) {
            eventsPublisher.publishJobInstanceEvent(jobInst, topicToPublish, correlationId);
        }
    }
202746
def publish(self, topic, message):
        """"""
        self.connect()
        log.info('publish {}'.format(message))
        self.client.publish(topic, message)
402916
@EventHandler("command")
    private void onCommand(CommandEvent event) {
        if (isEnabled()) {
            for (BaseComponent child : container.getChildren()) {
                EventUtil.send(event, child);

                if (event.isStopped()) {
                    break;
                }
            }
        }
    }
189829
def on(self):
        """"""
        on_command = StandardSend(self._address,
                                  COMMAND_LIGHT_ON_0X11_NONE, 0xff)
        self._send_method(on_command,
                          self._on_message_received)
243937
private void publish(Cache<K, V> cache, EventType eventType,
      K key, @Nullable V oldValue, @Nullable V newValue, boolean quiet) {
    if (dispatchQueues.isEmpty()) {
      return;
    }

    JCacheEntryEvent<K, V> event = null;
    for (Registration<K, V> registration : dispatchQueues.keySet()) {
      if (!registration.getCacheEntryListener().isCompatible(eventType)) {
        continue;
      }
      if (event == null) {
        event = new JCacheEntryEvent<>(cache, eventType, key, oldValue, newValue);
      }
      if (!registration.getCacheEntryFilter().evaluate(event)) {
        continue;
      }

      JCacheEntryEvent<K, V> e = event;
      CompletableFuture<Void> future =
          dispatchQueues.computeIfPresent(registration, (k, queue) -> {
            Runnable action = () -> registration.getCacheEntryListener().dispatch(e);
            return queue.thenRunAsync(action, executor);
          });
      if ((future != null) && registration.isSynchronous() && !quiet) {
        pending.get().add(future);
      }
    }
  }
427747
public function publish(EventInterface $event)
    {
        $commandsToDispatch = $this->eventBus->publish($event);

        $commands = $this->extractCommands($commandsToDispatch);
        foreach ($commands as $command) {
            $this->dispatch($command);
        }
    }
580724
public void publishCreated(Cache<K, V> cache, K key, V value) {
    publish(cache, EventType.CREATED, key, /* newValue */ null, value, /* quiet */ false);
  }
436211
def post_command_event(target, msg_cls, **kwargs):
    

    msg = msg_cls(id=-1, **kwargs)
    wx.PostEvent(target, msg)