aboutsummaryrefslogtreecommitdiff
path: root/Emby.Dlna/ProfileSerialization/ProfileCondition.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Emby.Dlna/ProfileSerialization/ProfileCondition.cs')
-rw-r--r--Emby.Dlna/ProfileSerialization/ProfileCondition.cs39
1 files changed, 39 insertions, 0 deletions
diff --git a/Emby.Dlna/ProfileSerialization/ProfileCondition.cs b/Emby.Dlna/ProfileSerialization/ProfileCondition.cs
new file mode 100644
index 0000000000..4169800e03
--- /dev/null
+++ b/Emby.Dlna/ProfileSerialization/ProfileCondition.cs
@@ -0,0 +1,39 @@
+using System.Xml.Serialization;
+using MediaBrowser.Model.Dlna;
+
+namespace MediaBrowser.Dlna.ProfileSerialization
+{
+ public class ProfileCondition
+ {
+ [XmlAttribute("condition")]
+ public ProfileConditionType Condition { get; set; }
+
+ [XmlAttribute("property")]
+ public ProfileConditionValue Property { get; set; }
+
+ [XmlAttribute("value")]
+ public string Value { get; set; }
+
+ [XmlAttribute("isRequired")]
+ public bool IsRequired { get; set; }
+
+ public ProfileCondition()
+ {
+ IsRequired = true;
+ }
+
+ public ProfileCondition(ProfileConditionType condition, ProfileConditionValue property, string value)
+ : this(condition, property, value, false)
+ {
+
+ }
+
+ public ProfileCondition(ProfileConditionType condition, ProfileConditionValue property, string value, bool isRequired)
+ {
+ Condition = condition;
+ Property = property;
+ Value = value;
+ IsRequired = isRequired;
+ }
+ }
+} \ No newline at end of file