/[xmltv_parser]/trunk/libxmltv/Core/PropertyDictionary.cs
ViewVC logotype

Diff of /trunk/libxmltv/Core/PropertyDictionary.cs

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

--- trunk/libxmltv/Core/PropertyDictionary.cs	2013/03/10 08:44:53	93
+++ trunk/libxmltv/Core/PropertyDictionary.cs	2013/03/10 09:01:33	95
@@ -10,7 +10,7 @@
 
 namespace libxmltv.Core
 {
-
+    
     public class PropertyCollection<T> : IPropertyCollection<T>
     {
         private List<T> items = new List<T>();
@@ -26,12 +26,9 @@
         public IEnumerator<T> GetEnumerator() { return items.GetEnumerator(); }
         System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { return items.GetEnumerator(); }
     }
-    public class PropertyDictionary : PropertyDictionary<string, object> 
+    public class PropertyDictionary : PropertyDictionary<string, object>, IPropertyDictionary
     {
-        public PropertyDictionary() : base() 
-        {
-            ThrowHelper.ThrowNotSupportedException(ExceptionResource.NotSupported_ReadOnlyCollection);
-        }
+        public PropertyDictionary() : base() { }
         public PropertyDictionary(IPropertyDictionary dictionary) : base(dictionary) { }
         public PropertyDictionary(IEqualityComparer<string> comparer) : base(comparer) { }
         public PropertyDictionary(int capacity) :base(capacity) { }
@@ -119,7 +116,7 @@
         public bool RemoveProperty(TKey key) { return properties.Remove(key); }
         public bool TryGetPropertyValue(TKey key, out TValue value) { return properties.TryGetValue(key, out value); }
         public int PropertyCount { get { return properties.Count; } }
-        public bool IsReadOnly { get { return (properties as ICollection<TKey>).IsReadOnly; } }
+        public bool IsReadOnly { get { return (properties as IPropertyCollection<TKey>).IsReadOnly; } }
         public void AddProperty(PropertyValuePair<TKey, TValue> item) { AddProperty(item.Name, item.Value); }
         public void ClearProperties() { properties.Clear(); }
         public bool ContainsProperty(PropertyValuePair<TKey, TValue> item) { return ContainsProperty(item.Name); }

 

  ViewVC Help
Powered by ViewVC 1.1.22