private void PublishMessages() { log.Debug("Publishing {type}", "messages"); for (ushort i = 1; i <= OmniLink.Controller.Messages.Count; i++) { clsMessage message = OmniLink.Controller.Messages[i]; if (message.DefaultProperties == true) { PublishAsync(message.ToTopic(Topic.name), null); continue; } PublishMessageState(message); PublishAsync(message.ToTopic(Topic.name), message.Name); } }
private void PublishMessageState(clsMessage message) { PublishAsync(message.ToTopic(Topic.state), message.ToState()); }