using System.Threading;
using MediaBrowser.Controller.Session;
using MediaBrowser.Model.SyncPlay;
namespace MediaBrowser.Controller.SyncPlay.PlaybackRequests
{
///
/// Class PingGroupRequest.
///
public class PingGroupRequest : IGroupPlaybackRequest
{
///
/// Initializes a new instance of the class.
///
/// The ping time.
public PingGroupRequest(long ping)
{
Ping = ping;
}
///
/// Gets the ping time.
///
/// The ping time.
public long Ping { get; }
///
public PlaybackRequestType Type { get; } = PlaybackRequestType.Ping;
///
public void Apply(IGroupStateContext context, IGroupState state, SessionInfo session, CancellationToken cancellationToken)
{
state.HandleRequest(context, state.Type, this, session, cancellationToken);
}
}
}