blam r633 - trunk/src



Author: cmartin
Date: Mon Sep  8 15:26:50 2008
New Revision: 633
URL: http://svn.gnome.org/viewvc/blam?rev=633&view=rev

Log:
Make GetItem part of IChannel.

Modified:
   trunk/src/Channel.cs
   trunk/src/ChannelGroup.cs

Modified: trunk/src/Channel.cs
==============================================================================
--- trunk/src/Channel.cs	(original)
+++ trunk/src/Channel.cs	Mon Sep  8 15:26:50 2008
@@ -21,6 +21,7 @@
         string Url {get; set; }
         ArrayList Items {get; set; }
         bool MarkAsRead();
+        Item GetItem(string id);
     }
 
     public class Channel : IChannel {

Modified: trunk/src/ChannelGroup.cs
==============================================================================
--- trunk/src/ChannelGroup.cs	(original)
+++ trunk/src/ChannelGroup.cs	Mon Sep  8 15:26:50 2008
@@ -79,5 +79,17 @@
             }
             return ret; /* FIXME: We shoudl probably do this some other way. */
         }
+
+        public Item GetItem(string id)
+        {
+            Item item = null;
+            foreach(IChannel ch in Channels){
+                item = ch.GetItem(id);
+                if(item != null){
+                    return item;
+                }
+            }
+            return null;
+        }
     }
 }



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]