2020-11-14 22:40:01 +00:00
|
|
|
using System;
|
2020-06-03 09:54:01 +00:00
|
|
|
|
2020-05-06 21:42:53 +00:00
|
|
|
namespace MediaBrowser.Model.SyncPlay
|
2020-04-01 15:52:42 +00:00
|
|
|
{
|
|
|
|
/// <summary>
|
2020-04-15 16:03:58 +00:00
|
|
|
/// Class SendCommand.
|
2020-04-01 15:52:42 +00:00
|
|
|
/// </summary>
|
2020-04-15 16:03:58 +00:00
|
|
|
public class SendCommand
|
2020-04-01 15:52:42 +00:00
|
|
|
{
|
2020-11-14 22:40:01 +00:00
|
|
|
/// <summary>
|
|
|
|
/// Initializes a new instance of the <see cref="SendCommand"/> class.
|
|
|
|
/// </summary>
|
2020-11-15 16:03:27 +00:00
|
|
|
/// <param name="groupId">The group identifier.</param>
|
|
|
|
/// <param name="playlistItemId">The playlist identifier of the playing item.</param>
|
|
|
|
/// <param name="when">The UTC time when to execute the command.</param>
|
|
|
|
/// <param name="command">The command.</param>
|
|
|
|
/// <param name="positionTicks">The position ticks, for commands that require it.</param>
|
|
|
|
/// <param name="emittedAt">The UTC time when this command has been emitted.</param>
|
2020-12-04 19:15:16 +00:00
|
|
|
public SendCommand(Guid groupId, Guid playlistItemId, DateTime when, SendCommandType command, long? positionTicks, DateTime emittedAt)
|
2020-11-14 22:40:01 +00:00
|
|
|
{
|
2020-11-15 16:03:27 +00:00
|
|
|
GroupId = groupId;
|
|
|
|
PlaylistItemId = playlistItemId;
|
|
|
|
When = when;
|
|
|
|
Command = command;
|
|
|
|
PositionTicks = positionTicks;
|
|
|
|
EmittedAt = emittedAt;
|
2020-11-14 22:40:01 +00:00
|
|
|
}
|
|
|
|
|
2020-04-01 15:52:42 +00:00
|
|
|
/// <summary>
|
2020-11-15 16:03:27 +00:00
|
|
|
/// Gets the group identifier.
|
2020-04-01 15:52:42 +00:00
|
|
|
/// </summary>
|
|
|
|
/// <value>The group identifier.</value>
|
2020-11-15 16:03:27 +00:00
|
|
|
public Guid GroupId { get; }
|
2020-04-01 15:52:42 +00:00
|
|
|
|
2020-09-24 21:04:21 +00:00
|
|
|
/// <summary>
|
2020-11-15 16:03:27 +00:00
|
|
|
/// Gets the playlist identifier of the playing item.
|
2020-09-24 21:04:21 +00:00
|
|
|
/// </summary>
|
2020-10-21 14:42:57 +00:00
|
|
|
/// <value>The playlist identifier of the playing item.</value>
|
2020-12-04 19:15:16 +00:00
|
|
|
public Guid PlaylistItemId { get; }
|
2020-09-24 21:04:21 +00:00
|
|
|
|
2020-04-01 15:52:42 +00:00
|
|
|
/// <summary>
|
|
|
|
/// Gets or sets the UTC time when to execute the command.
|
|
|
|
/// </summary>
|
|
|
|
/// <value>The UTC time when to execute the command.</value>
|
2020-11-14 22:40:01 +00:00
|
|
|
public DateTime When { get; set; }
|
2020-04-01 15:52:42 +00:00
|
|
|
|
|
|
|
/// <summary>
|
2020-11-15 16:03:27 +00:00
|
|
|
/// Gets the position ticks.
|
2020-04-01 15:52:42 +00:00
|
|
|
/// </summary>
|
|
|
|
/// <value>The position ticks.</value>
|
2020-11-15 16:03:27 +00:00
|
|
|
public long? PositionTicks { get; }
|
2020-04-01 15:52:42 +00:00
|
|
|
|
|
|
|
/// <summary>
|
2020-11-15 16:03:27 +00:00
|
|
|
/// Gets the command.
|
2020-04-01 15:52:42 +00:00
|
|
|
/// </summary>
|
|
|
|
/// <value>The command.</value>
|
2020-11-15 16:03:27 +00:00
|
|
|
public SendCommandType Command { get; }
|
2020-04-15 16:03:58 +00:00
|
|
|
|
|
|
|
/// <summary>
|
2020-11-15 16:03:27 +00:00
|
|
|
/// Gets the UTC time when this command has been emitted.
|
2020-04-15 16:03:58 +00:00
|
|
|
/// </summary>
|
|
|
|
/// <value>The UTC time when this command has been emitted.</value>
|
2020-11-15 16:03:27 +00:00
|
|
|
public DateTime EmittedAt { get; }
|
2020-04-01 15:52:42 +00:00
|
|
|
}
|
|
|
|
}
|