using adas_core.Application.Subscriptions; using MongoDB.Bson; namespace adas_core.Application.Services.Interfaces; public interface ISubscribersService { /// /// Retrieves the list of subscribers. /// /// A list of instances representing the subscribers. List GetSubscribers(); /// /// Retrieves a associated with the specified context connection identifier. /// /// The unique identifier of the context connection used to look up the subscriber. /// The matching the given connection identifier, or null if no subscriber is found. WsSubscriber? GetById(string contextConnectionId); /// /// Retrieves the list of subscribers associated with the specified point of contact (POC) identifier. /// /// The identifier of the point of contact whose subscribers should be returned. /// A list of instances matching the provided POC identifier. List GetByPocId(ObjectId pocId); /// /// Removes a connection identified by the specified context connection identifier. /// /// The unique identifier of the connection to remove. /// An integer indicating the result of the removal operation. int RemoveConnectionById(string contextConnectionId); /// /// Registers the specified WebSocket subscriber to receive notifications or messages. /// /// The instance to be added to the collection of subscribers. void AddSubscriber(WsSubscriber subscriber); }