You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
67 lines
2.3 KiB
67 lines
2.3 KiB
5 years ago
|
using System;
|
||
5 years ago
|
using System.Threading;
|
||
5 years ago
|
using MediaBrowser.Controller.Session;
|
||
5 years ago
|
using MediaBrowser.Model.SyncPlay;
|
||
5 years ago
|
|
||
5 years ago
|
namespace MediaBrowser.Controller.SyncPlay
|
||
5 years ago
|
{
|
||
|
/// <summary>
|
||
5 years ago
|
/// Interface ISyncPlayController.
|
||
5 years ago
|
/// </summary>
|
||
5 years ago
|
public interface ISyncPlayController
|
||
5 years ago
|
{
|
||
|
/// <summary>
|
||
|
/// Gets the group id.
|
||
|
/// </summary>
|
||
|
/// <value>The group id.</value>
|
||
|
Guid GetGroupId();
|
||
|
|
||
|
/// <summary>
|
||
|
/// Gets the playing item id.
|
||
|
/// </summary>
|
||
|
/// <value>The playing item id.</value>
|
||
|
Guid GetPlayingItemId();
|
||
|
|
||
|
/// <summary>
|
||
|
/// Checks if the group is empty.
|
||
|
/// </summary>
|
||
|
/// <value>If the group is empty.</value>
|
||
|
bool IsGroupEmpty();
|
||
|
|
||
|
/// <summary>
|
||
5 years ago
|
/// Initializes the group with the session's info.
|
||
5 years ago
|
/// </summary>
|
||
5 years ago
|
/// <param name="session">The session.</param>
|
||
5 years ago
|
/// <param name="cancellationToken">The cancellation token.</param>
|
||
|
void InitGroup(SessionInfo session, CancellationToken cancellationToken);
|
||
5 years ago
|
|
||
|
/// <summary>
|
||
5 years ago
|
/// Adds the session to the group.
|
||
5 years ago
|
/// </summary>
|
||
5 years ago
|
/// <param name="session">The session.</param>
|
||
5 years ago
|
/// <param name="request">The request.</param>
|
||
5 years ago
|
/// <param name="cancellationToken">The cancellation token.</param>
|
||
|
void SessionJoin(SessionInfo session, JoinGroupRequest request, CancellationToken cancellationToken);
|
||
5 years ago
|
|
||
|
/// <summary>
|
||
5 years ago
|
/// Removes the session from the group.
|
||
5 years ago
|
/// </summary>
|
||
5 years ago
|
/// <param name="session">The session.</param>
|
||
5 years ago
|
/// <param name="cancellationToken">The cancellation token.</param>
|
||
|
void SessionLeave(SessionInfo session, CancellationToken cancellationToken);
|
||
5 years ago
|
|
||
|
/// <summary>
|
||
5 years ago
|
/// Handles the requested action by the session.
|
||
5 years ago
|
/// </summary>
|
||
5 years ago
|
/// <param name="session">The session.</param>
|
||
5 years ago
|
/// <param name="request">The requested action.</param>
|
||
5 years ago
|
/// <param name="cancellationToken">The cancellation token.</param>
|
||
|
void HandleRequest(SessionInfo session, PlaybackRequest request, CancellationToken cancellationToken);
|
||
5 years ago
|
|
||
|
/// <summary>
|
||
|
/// Gets the info about the group for the clients.
|
||
|
/// </summary>
|
||
|
/// <value>The group info for the clients.</value>
|
||
|
GroupInfoView GetInfo();
|
||
|
}
|
||
|
}
|