|
|
|
@ -342,15 +342,6 @@ namespace MediaBrowser.Model.Dto
|
|
|
|
|
/// <value><c>true</c> if this instance is folder; otherwise, <c>false</c>.</value>
|
|
|
|
|
public bool? IsFolder { get; set; }
|
|
|
|
|
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public bool IsFolderItem
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
return IsFolder ?? false;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets the parent id.
|
|
|
|
|
/// </summary>
|
|
|
|
@ -458,56 +449,6 @@ namespace MediaBrowser.Model.Dto
|
|
|
|
|
/// <value>The status.</value>
|
|
|
|
|
public string Status { get; set; }
|
|
|
|
|
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public SeriesStatus? SeriesStatus
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
if (string.IsNullOrEmpty(Status))
|
|
|
|
|
{
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return (SeriesStatus)Enum.Parse(typeof(SeriesStatus), Status, true);
|
|
|
|
|
}
|
|
|
|
|
set
|
|
|
|
|
{
|
|
|
|
|
if (value == null)
|
|
|
|
|
{
|
|
|
|
|
Status = null;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
Status = value.Value.ToString();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public RecordingStatus? RecordingStatus
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
if (string.IsNullOrEmpty(Status))
|
|
|
|
|
{
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return (RecordingStatus)Enum.Parse(typeof(RecordingStatus), Status, true);
|
|
|
|
|
}
|
|
|
|
|
set
|
|
|
|
|
{
|
|
|
|
|
if (value == null)
|
|
|
|
|
{
|
|
|
|
|
Status = null;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
Status = value.Value.ToString();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets the air time.
|
|
|
|
|
/// </summary>
|
|
|
|
@ -650,19 +591,6 @@ namespace MediaBrowser.Model.Dto
|
|
|
|
|
return IsType(type.Name);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets a value indicating whether [supports playlists].
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <value><c>true</c> if [supports playlists]; otherwise, <c>false</c>.</value>
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public bool SupportsPlaylists
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
return RunTimeTicks.HasValue || IsFolderItem || IsGenre || IsMusicGenre || IsArtist;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Determines whether the specified type is type.
|
|
|
|
|
/// </summary>
|
|
|
|
@ -876,56 +804,6 @@ namespace MediaBrowser.Model.Dto
|
|
|
|
|
/// <value>The series timer identifier.</value>
|
|
|
|
|
public string SeriesTimerId { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a value indicating whether this instance can resume.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <value><c>true</c> if this instance can resume; otherwise, <c>false</c>.</value>
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public bool CanResume
|
|
|
|
|
{
|
|
|
|
|
get { return UserData != null && UserData.PlaybackPositionTicks > 0; }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets the resume position ticks.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <value>The resume position ticks.</value>
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public long ResumePositionTicks
|
|
|
|
|
{
|
|
|
|
|
get { return UserData == null ? 0 : UserData.PlaybackPositionTicks; }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets the backdrop count.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <value>The backdrop count.</value>
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public int BackdropCount
|
|
|
|
|
{
|
|
|
|
|
get { return BackdropImageTags == null ? 0 : BackdropImageTags.Count; }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets the screenshot count.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <value>The screenshot count.</value>
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public int ScreenshotCount
|
|
|
|
|
{
|
|
|
|
|
get { return ScreenshotImageTags == null ? 0 : ScreenshotImageTags.Count; }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a value indicating whether this instance has banner.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <value><c>true</c> if this instance has banner; otherwise, <c>false</c>.</value>
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public bool HasBanner
|
|
|
|
|
{
|
|
|
|
|
get { return ImageTags != null && ImageTags.ContainsKey(ImageType.Banner); }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a value indicating whether this instance has art.
|
|
|
|
|
/// </summary>
|
|
|
|
@ -976,46 +854,6 @@ namespace MediaBrowser.Model.Dto
|
|
|
|
|
get { return ImageTags != null && ImageTags.ContainsKey(ImageType.Primary); }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a value indicating whether this instance has disc image.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <value><c>true</c> if this instance has disc image; otherwise, <c>false</c>.</value>
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public bool HasDiscImage
|
|
|
|
|
{
|
|
|
|
|
get { return ImageTags != null && ImageTags.ContainsKey(ImageType.Disc); }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a value indicating whether this instance has box image.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <value><c>true</c> if this instance has box image; otherwise, <c>false</c>.</value>
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public bool HasBoxImage
|
|
|
|
|
{
|
|
|
|
|
get { return ImageTags != null && ImageTags.ContainsKey(ImageType.Box); }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a value indicating whether this instance has box image.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <value><c>true</c> if this instance has box image; otherwise, <c>false</c>.</value>
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public bool HasBoxRearImage
|
|
|
|
|
{
|
|
|
|
|
get { return ImageTags != null && ImageTags.ContainsKey(ImageType.BoxRear); }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a value indicating whether this instance has menu image.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <value><c>true</c> if this instance has menu image; otherwise, <c>false</c>.</value>
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public bool HasMenuImage
|
|
|
|
|
{
|
|
|
|
|
get { return ImageTags != null && ImageTags.ContainsKey(ImageType.Menu); }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a value indicating whether this instance is video.
|
|
|
|
|
/// </summary>
|
|
|
|
@ -1056,16 +894,6 @@ namespace MediaBrowser.Model.Dto
|
|
|
|
|
get { return StringHelper.EqualsIgnoreCase(Type, "Person"); }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a value indicating whether this instance is root.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <value><c>true</c> if this instance is root; otherwise, <c>false</c>.</value>
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public bool IsRoot
|
|
|
|
|
{
|
|
|
|
|
get { return StringHelper.EqualsIgnoreCase(Type, "AggregateFolder"); }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public bool IsMusicGenre
|
|
|
|
|
{
|
|
|
|
|