aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Model
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Model')
-rw-r--r--MediaBrowser.Model/MediaBrowser.Model.csproj5
-rw-r--r--MediaBrowser.Model/Session/BrowseRequest.cs37
-rw-r--r--MediaBrowser.Model/Session/PlayRequest.cs46
-rw-r--r--MediaBrowser.Model/Session/PlaystateRequest.cs53
-rw-r--r--MediaBrowser.Model/Session/SessionInfoDto.cs (renamed from MediaBrowser.Model/Session/SessionInfo.cs)11
5 files changed, 147 insertions, 5 deletions
diff --git a/MediaBrowser.Model/MediaBrowser.Model.csproj b/MediaBrowser.Model/MediaBrowser.Model.csproj
index dbfe38698..979e0d55e 100644
--- a/MediaBrowser.Model/MediaBrowser.Model.csproj
+++ b/MediaBrowser.Model/MediaBrowser.Model.csproj
@@ -56,7 +56,9 @@
<Compile Include="Querying\ArtistsQuery.cs" />
<Compile Include="Querying\ItemsByNameQuery.cs" />
<Compile Include="Entities\BaseItemInfo.cs" />
- <Compile Include="Session\SessionInfo.cs" />
+ <Compile Include="Session\BrowseRequest.cs" />
+ <Compile Include="Session\PlayRequest.cs" />
+ <Compile Include="Session\PlaystateRequest.cs" />
<Compile Include="Entities\ImageDownloadOptions.cs" />
<Compile Include="Logging\ILogManager.cs" />
<Compile Include="MediaInfo\BlurayDiscInfo.cs" />
@@ -92,6 +94,7 @@
<Compile Include="Search\SearchHintResult.cs" />
<Compile Include="Serialization\IJsonSerializer.cs" />
<Compile Include="Serialization\IXmlSerializer.cs" />
+ <Compile Include="Session\SessionInfoDto.cs" />
<Compile Include="Updates\CheckForUpdateResult.cs" />
<Compile Include="Updates\PackageTargetSystem.cs" />
<Compile Include="Updates\InstallationInfo.cs" />
diff --git a/MediaBrowser.Model/Session/BrowseRequest.cs b/MediaBrowser.Model/Session/BrowseRequest.cs
new file mode 100644
index 000000000..3d10b3bfd
--- /dev/null
+++ b/MediaBrowser.Model/Session/BrowseRequest.cs
@@ -0,0 +1,37 @@
+
+namespace MediaBrowser.Model.Session
+{
+ /// <summary>
+ /// Class BrowseRequest
+ /// </summary>
+ public class BrowseRequest
+ {
+ /// <summary>
+ /// Artist, Genre, Studio, Person, or any kind of BaseItem
+ /// </summary>
+ /// <value>The type of the item.</value>
+ public string ItemType { get; set; }
+
+ /// <summary>
+ /// Artist name, genre name, item Id, etc
+ /// </summary>
+ /// <value>The item identifier.</value>
+ public string ItemIdentifier { get; set; }
+
+ /// <summary>
+ /// Gets or sets the context (Movies, Music, Tv, etc)
+ /// Applicable to genres, studios and persons only because the context of items and artists can be inferred.
+ /// This is optional to supply and clients are free to ignore it.
+ /// </summary>
+ /// <value>The context.</value>
+ public string Context { get; set; }
+ }
+
+ public class ItemContext
+ {
+ public const string Music = "Music";
+ public const string Movies = "Movies";
+ public const string TvShows = "TvShows";
+ public const string Games = "Games";
+ }
+}
diff --git a/MediaBrowser.Model/Session/PlayRequest.cs b/MediaBrowser.Model/Session/PlayRequest.cs
new file mode 100644
index 000000000..c9bb58693
--- /dev/null
+++ b/MediaBrowser.Model/Session/PlayRequest.cs
@@ -0,0 +1,46 @@
+
+namespace MediaBrowser.Model.Session
+{
+ /// <summary>
+ /// Class PlayRequest
+ /// </summary>
+ public class PlayRequest
+ {
+ /// <summary>
+ /// Gets or sets the item ids.
+ /// </summary>
+ /// <value>The item ids.</value>
+ public string[] ItemIds { get; set; }
+
+ /// <summary>
+ /// Gets or sets the start position ticks that the first item should be played at
+ /// </summary>
+ /// <value>The start position ticks.</value>
+ public long? StartPositionTicks { get; set; }
+
+ /// <summary>
+ /// Gets or sets the play command.
+ /// </summary>
+ /// <value>The play command.</value>
+ public PlayCommand PlayCommand { get; set; }
+ }
+
+ /// <summary>
+ /// Enum PlayCommand
+ /// </summary>
+ public enum PlayCommand
+ {
+ /// <summary>
+ /// The play now
+ /// </summary>
+ PlayNow,
+ /// <summary>
+ /// The play next
+ /// </summary>
+ PlayNext,
+ /// <summary>
+ /// The play last
+ /// </summary>
+ PlayLast
+ }
+}
diff --git a/MediaBrowser.Model/Session/PlaystateRequest.cs b/MediaBrowser.Model/Session/PlaystateRequest.cs
new file mode 100644
index 000000000..4db06c3d6
--- /dev/null
+++ b/MediaBrowser.Model/Session/PlaystateRequest.cs
@@ -0,0 +1,53 @@
+
+namespace MediaBrowser.Model.Session
+{
+ /// <summary>
+ /// Class PlaystateRequest
+ /// </summary>
+ public class PlaystateRequest
+ {
+ /// <summary>
+ /// Gets or sets the command.
+ /// </summary>
+ /// <value>The command.</value>
+ public PlaystateCommand Command { get; set; }
+
+ /// <summary>
+ /// Gets or sets the seek position.
+ /// Only applicable to seek commands.
+ /// </summary>
+ /// <value>The seek position.</value>
+ public long SeekPosition { get; set; }
+ }
+
+ /// <summary>
+ /// Enum PlaystateCommand
+ /// </summary>
+ public enum PlaystateCommand
+ {
+ /// <summary>
+ /// The stop
+ /// </summary>
+ Stop,
+ /// <summary>
+ /// The pause
+ /// </summary>
+ Pause,
+ /// <summary>
+ /// The unpause
+ /// </summary>
+ Unpause,
+ /// <summary>
+ /// The next track
+ /// </summary>
+ NextTrack,
+ /// <summary>
+ /// The previous track
+ /// </summary>
+ PreviousTrack,
+ /// <summary>
+ /// The seek
+ /// </summary>
+ Seek
+ }
+}
diff --git a/MediaBrowser.Model/Session/SessionInfo.cs b/MediaBrowser.Model/Session/SessionInfoDto.cs
index f74db9058..0548876a1 100644
--- a/MediaBrowser.Model/Session/SessionInfo.cs
+++ b/MediaBrowser.Model/Session/SessionInfoDto.cs
@@ -3,10 +3,7 @@ using System;
namespace MediaBrowser.Model.Session
{
- /// <summary>
- /// Class SessionInfo
- /// </summary>
- public class SessionInfo
+ public class SessionInfoDto
{
/// <summary>
/// Gets or sets the id.
@@ -55,5 +52,11 @@ namespace MediaBrowser.Model.Session
/// </summary>
/// <value>The device id.</value>
public string DeviceId { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether [supports remote control].
+ /// </summary>
+ /// <value><c>true</c> if [supports remote control]; otherwise, <c>false</c>.</value>
+ public bool SupportsRemoteControl { get; set; }
}
}