Beispiel #1
0
 /// <summary>
 /// Schedules the collection of fanart for the media item with the specified <paramref name="mediaItemId"/>.
 /// </summary>
 /// <param name="mediaItemId">The media item id of the media item to collect fanart for.</param>
 public void ScheduleFanArtCollection(Guid mediaItemId)
 {
     ServiceRegistration.Get <ILogger>().Debug("FanArtManagement: Scheduling fanart collection for {0}.", mediaItemId);
     if (!_fanartActionBlock.Post(new FanArtManagerAction(ActionType.Collect, mediaItemId)))
     {
         ServiceRegistration.Get <ILogger>().Warn("FanArtManagement: Failed to scheduling fanart collection for {0}.", mediaItemId);
     }
 }
Beispiel #2
0
        /// <summary>
        /// Schedules the collection of fanart for the media item with the specified <paramref name="mediaItemId"/> and <paramref name="aspects"/>.
        /// </summary>
        /// <param name="mediaItemId">The media item id of the media item to collect fanart for.</param>
        /// <param name="aspects">The media item aspects of the media item to collect fanart for.</param>
        public void ScheduleFanArtCollection(Guid mediaItemId, IDictionary <Guid, IList <MediaItemAspect> > aspects)
        {
            if (aspects == null)
            {
                throw new ArgumentNullException("aspects", "cannot be null");
            }

            ServiceRegistration.Get <ILogger>().Debug("FanArtManagement: Scheduling fanart collection for {0}.", mediaItemId);
            _fanartActionBlock.Post(new FanArtManagerAction(ActionType.Collect, mediaItemId, aspects));
        }