using System.Threading;
using MediaBrowser.Controller.Session;
using MediaBrowser.Model.SyncPlay;
namespace MediaBrowser.Controller.SyncPlay.PlaybackRequests
{
///
/// Class PingGroupRequest.
///
public class PingGroupRequest : AbstractPlaybackRequest
{
///
/// 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 override PlaybackRequestType Action { get; } = PlaybackRequestType.Ping;
///
public override void Apply(IGroupStateContext context, IGroupState state, SessionInfo session, CancellationToken cancellationToken)
{
state.HandleRequest(context, state.Type, this, session, cancellationToken);
}
}
}