using MediaBrowser.Model.Entities;
using System;
using System.Collections.Generic;
using System.Linq;
namespace MediaBrowser.Controller.Entities
{
public interface IHasTrailers : IHasProviderIds
{
///
/// Gets or sets the remote trailers.
///
/// The remote trailers.
List RemoteTrailers { get; set; }
///
/// Gets or sets the local trailer ids.
///
/// The local trailer ids.
List LocalTrailerIds { get; set; }
List RemoteTrailerIds { get; set; }
}
public static class HasTrailerExtensions
{
///
/// Gets the trailer ids.
///
/// List<Guid>.
public static List GetTrailerIds(this IHasTrailers item)
{
var list = item.LocalTrailerIds.ToList();
list.AddRange(item.RemoteTrailerIds);
return list;
}
}
}