IChatConnectionTracker.cs 518 B

12345678910111213141516
  1. namespace Application.Abstractions.Chat;
  2. public interface IChatConnectionTracker
  3. {
  4. Task AddAsync(string roomKey, ConnectedUser user);
  5. Task RemoveAsync(string roomKey, string connectionId);
  6. Task<IReadOnlyList<ConnectedUser>> GetByRoomAsync(string roomKey);
  7. Task<int> GetCountByRoomAsync(string roomKey);
  8. // 전체 룸에 걸친 접속자 + 룸 키 (관리자 집계용)
  9. Task<IReadOnlyList<(
  10. string RoomKey,
  11. ConnectedUser User
  12. )>> GetAllAsync();
  13. Task ClearAllAsync();
  14. }