ContainerProfile.cs 674 B

1234567891011121314151617181920212223242526
  1. using System.Collections.Generic;
  2. using System.Linq;
  3. using System.Xml.Serialization;
  4. namespace MediaBrowser.Model.Dlna
  5. {
  6. public class ContainerProfile
  7. {
  8. [XmlAttribute("type")]
  9. public DlnaProfileType Type { get; set; }
  10. public ProfileCondition[] Conditions { get; set; }
  11. [XmlAttribute("container")]
  12. public string Container { get; set; }
  13. public ContainerProfile()
  14. {
  15. Conditions = new ProfileCondition[] { };
  16. }
  17. public List<string> GetContainers()
  18. {
  19. return (Container ?? string.Empty).Split(',').Where(i => !string.IsNullOrEmpty(i)).ToList();
  20. }
  21. }
  22. }