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