/[xmltv_parser]/trunk/libxmltv/Interfaces/Interfaces.cs
ViewVC logotype

Diff of /trunk/libxmltv/Interfaces/Interfaces.cs

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

--- trunk/libxmltv/Interfaces/Interfaces.cs	2013/03/09 09:29:40	72
+++ trunk/libxmltv/Interfaces/Interfaces.cs	2013/03/09 13:51:58	86
@@ -36,24 +36,37 @@
         string Name { get; }
         string ToString();
     }
-    public interface IXMLTVProgram
+
+    public interface IPropertyDictionary : IPropertyDictionary<string, object>    {    }
+    public interface IPropertyDictionary<TKey,TValue>
     {
-        int Id { get; }
-        DateTime Start { get; }
-        DateTime Stop { get; }
-        IXMLTVChannel Channel { get; }
-        string Title { get; }
-        string SubTitle { get; }
-        string Description { get; }
-        string ToString();
+        Dictionary<TKey, TValue> Properties { get; }
+        TValue GetProperty(TKey name);
+        void SetProperty(TKey name, TValue value);
+    }
+    public interface IXMLTVProgram : IPropertyDictionary
+    {
+        //int Id { get; }
+        //DateTime Start { get; }
+        //DateTime Stop { get; }
+        //IXMLTVChannel Channel { get; }
+        //string Title { get; }
+        //string SubTitle { get; }
+        //string Description { get; }
+        //string ToString();
+        
     }
 
-    public interface IXMLTVProgramCollection : IXMLTVCollection<int, IXMLTVProgram> { }
-    public interface IXMLTVChannelCollection : IXMLTVCollection<string, IXMLTVChannel> { }
-    public interface IXMLTVCollection<TKey, TValue> { Dictionary<TKey, TValue> Collection { get; } }
+    public interface IXMLTVProgramCollection : IXMLTVDictionaryCollection<string, IXMLTVProgram> { }
+    public interface IXMLTVChannelCollection : IXMLTVDictionaryCollection<string, IXMLTVChannel> { }
+    public interface IXMLTVDictionaryCollection<TKey, TValue> { Dictionary<TKey, TValue> Collection { get; } }
+    public interface IXMLTVListCollection<TValue> { List<TValue> Collection { get; } }
+
+    public interface IXMLTVHandler : IXMLTVHandler<object> { }
+    public interface IXMLTVHandler<T> { T Handler { get; } }
 
     //public interface IXMLTVBase : IXMLTVBase<object> { }
-    public interface IXMLTVBase<T> : IGetInstance<T> { }
+    public interface IXMLTVBase<T> : IGetInstance<T>, IXMLTVHandler { }
     public interface IXMLTVRuntimeInstance : IOnInstanceCreated
     {
         bool IsAborting { get; } 
@@ -62,8 +75,8 @@
         string XmlFile_FullName { get; }
         string XmlDoc { get; }
         IXMLTVSource Source { get; }
-        Dictionary<string, IXMLTVChannel> Channels { get; }
-        Dictionary<int, IXMLTVProgram> Programs { get; }
+        List<IXMLTVChannel> Channels { get; }
+        List<IXMLTVProgram> Programs { get; }
         
     }
     public interface IXMLTVSerializer : IXMLTVSerializer<object> { }

 

  ViewVC Help
Powered by ViewVC 1.1.22