using System; namespace RobotLib.Communication { public interface IPublisherSubscriber { /// /// New message to a subscribed topic arrived. /// event EventHandler NewMessageArrived; /// /// Connection state. /// bool IsConnected { get; } /// /// Subscribe to a topic. /// /// The topic to subscribe to. void Subscribe(string topic); /// /// Publish message to a topic. /// /// The topic where to publish the data to. /// Data to publish. void Publish(string topic, string message); } }