UserRootFolder.cs 817 B

12345678910111213141516171819202122
  1. using System.Collections.Generic;
  2. using System.Linq;
  3. using MediaBrowser.Controller.Providers;
  4. namespace MediaBrowser.Controller.Entities
  5. {
  6. /// <summary>
  7. /// Special class used for User Roots. Children contain actual ones defined for this user
  8. /// PLUS the virtual folders from the physical root (added by plug-ins).
  9. /// </summary>
  10. public class UserRootFolder : Folder
  11. {
  12. /// <summary>
  13. /// Get the children of this folder from the actual file system
  14. /// </summary>
  15. /// <returns>IEnumerable{BaseItem}.</returns>
  16. protected override IEnumerable<BaseItem> GetNonCachedChildren(DirectoryService directoryService)
  17. {
  18. return base.GetNonCachedChildren(directoryService).Concat(LibraryManager.RootFolder.VirtualChildren);
  19. }
  20. }
  21. }