2014-03-23 09:42:02 -07:00
|
|
|
|
using System.Collections.Generic;
|
2014-03-26 08:06:48 -07:00
|
|
|
|
using System.Xml.Serialization;
|
2014-03-23 09:42:02 -07:00
|
|
|
|
|
2014-04-01 15:23:07 -07:00
|
|
|
|
namespace MediaBrowser.Model.Dlna
|
2014-03-23 09:42:02 -07:00
|
|
|
|
{
|
|
|
|
|
public class ContainerProfile
|
|
|
|
|
{
|
2014-03-26 08:06:48 -07:00
|
|
|
|
[XmlAttribute("type")]
|
2014-03-23 09:42:02 -07:00
|
|
|
|
public DlnaProfileType Type { get; set; }
|
|
|
|
|
public ProfileCondition[] Conditions { get; set; }
|
2014-03-26 08:06:48 -07:00
|
|
|
|
|
|
|
|
|
[XmlAttribute("container")]
|
2014-03-23 09:42:02 -07:00
|
|
|
|
public string Container { get; set; }
|
|
|
|
|
|
|
|
|
|
public ContainerProfile()
|
|
|
|
|
{
|
|
|
|
|
Conditions = new ProfileCondition[] { };
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public List<string> GetContainers()
|
|
|
|
|
{
|
2014-05-08 14:23:24 -07:00
|
|
|
|
List<string> list = new List<string>();
|
|
|
|
|
foreach (string i in (Container ?? string.Empty).Split(','))
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrEmpty(i)) list.Add(i);
|
|
|
|
|
}
|
|
|
|
|
return list;
|
2014-03-23 09:42:02 -07:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|