ISessionRemoteController.cs 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. using MediaBrowser.Model.Session;
  2. using System.Threading;
  3. using System.Threading.Tasks;
  4. namespace MediaBrowser.Controller.Session
  5. {
  6. public interface ISessionRemoteController
  7. {
  8. /// <summary>
  9. /// Supportses the specified session.
  10. /// </summary>
  11. /// <param name="session">The session.</param>
  12. /// <returns><c>true</c> if XXXX, <c>false</c> otherwise</returns>
  13. bool Supports(SessionInfo session);
  14. /// <summary>
  15. /// Sends the system command.
  16. /// </summary>
  17. /// <param name="session">The session.</param>
  18. /// <param name="command">The command.</param>
  19. /// <param name="cancellationToken">The cancellation token.</param>
  20. /// <returns>Task.</returns>
  21. Task SendSystemCommand(SessionInfo session, SystemCommand command, CancellationToken cancellationToken);
  22. /// <summary>
  23. /// Sends the message command.
  24. /// </summary>
  25. /// <param name="session">The session.</param>
  26. /// <param name="command">The command.</param>
  27. /// <param name="cancellationToken">The cancellation token.</param>
  28. /// <returns>Task.</returns>
  29. Task SendMessageCommand(SessionInfo session, MessageCommand command, CancellationToken cancellationToken);
  30. /// <summary>
  31. /// Sends the play command.
  32. /// </summary>
  33. /// <param name="session">The session.</param>
  34. /// <param name="command">The command.</param>
  35. /// <param name="cancellationToken">The cancellation token.</param>
  36. /// <returns>Task.</returns>
  37. Task SendPlayCommand(SessionInfo session, PlayRequest command, CancellationToken cancellationToken);
  38. /// <summary>
  39. /// Sends the browse command.
  40. /// </summary>
  41. /// <param name="session">The session.</param>
  42. /// <param name="command">The command.</param>
  43. /// <param name="cancellationToken">The cancellation token.</param>
  44. /// <returns>Task.</returns>
  45. Task SendBrowseCommand(SessionInfo session, BrowseRequest command, CancellationToken cancellationToken);
  46. /// <summary>
  47. /// Sends the playstate command.
  48. /// </summary>
  49. /// <param name="session">The session.</param>
  50. /// <param name="command">The command.</param>
  51. /// <param name="cancellationToken">The cancellation token.</param>
  52. /// <returns>Task.</returns>
  53. Task SendPlaystateCommand(SessionInfo session, PlaystateRequest command, CancellationToken cancellationToken);
  54. }
  55. }