Author: fmantek
Date: Tue Sep 18 04:59:41 2007
New Revision: 258

Modified:
   trunk/clients/cs/RELEASE_NOTES.HTML
   trunk/clients/cs/src/core/abstractentry.cs
   trunk/clients/cs/src/core/abstractfeed.cs
   trunk/clients/cs/src/core/atombase.cs
   trunk/clients/cs/src/core/serviceinterface.cs
   trunk/clients/cs/src/extensions/extensionbase.cs
   trunk/clients/cs/src/extensions/reminder.cs
   trunk/clients/cs/src/extensions/simplecontainer.cs
   trunk/clients/cs/src/extensions/simpleelement.cs
   trunk/clients/cs/src/extensions/when.cs
   trunk/clients/cs/src/extensions/where.cs
   trunk/clients/cs/src/gcalendar/calendarentry.cs
   trunk/clients/cs/src/gcalendar/evententry.cs
   trunk/clients/cs/src/gcalendar/eventfeed.cs
   trunk/clients/cs/src/gcalendar/webcontent.cs

Log:
added the parser parameter back to CreateInstance (there is one element that 
needs it...).

Move gd:where and gcal:timezone to the new extension model. 

Modified: trunk/clients/cs/RELEASE_NOTES.HTML
==============================================================================
--- trunk/clients/cs/RELEASE_NOTES.HTML (original)
+++ trunk/clients/cs/RELEASE_NOTES.HTML Tue Sep 18 04:59:41 2007
@@ -102,9 +102,9 @@
         has a QuickAdd boolean property. Setting it to true causes an insert to
         be treated like a quickAdd operation. 
     </li> 
-    <li>Added new methods on the AtomCategoyr collection. Find searches for 
-        a category of a given term, or a term/scheme combination. Also changed
-        the implementation of the Contains method to compare not just object
+    <li>Added new methods on the AtomCategory collection. Find searches for a
+        category of a given term, or a term/scheme combination. Also changed 
the
+        implementation of the Contains method to compare not just object
         fidelity, but also term/value pairs
         </li>
     <li>Added a ConvertToXSDSTring() helper in the Utilites class. As booleans 

Modified: trunk/clients/cs/src/core/abstractentry.cs
==============================================================================
--- trunk/clients/cs/src/core/abstractentry.cs  (original)
+++ trunk/clients/cs/src/core/abstractentry.cs  Tue Sep 18 04:59:41 2007
@@ -83,7 +83,7 @@
                                                                   
node.NamespaceURI);
                 if (f != null)
                 {
-                    this.ExtensionElements.Add(f.CreateInstance(node));
+                    this.ExtensionElements.Add(f.CreateInstance(node, parser));
                     e.DiscardEntry = true;
                 }
             }

Modified: trunk/clients/cs/src/core/abstractfeed.cs
==============================================================================
--- trunk/clients/cs/src/core/abstractfeed.cs   (original)
+++ trunk/clients/cs/src/core/abstractfeed.cs   Tue Sep 18 04:59:41 2007
@@ -153,7 +153,7 @@
                     {
                         if (String.Compare(node.LocalName, f.XmlName) == 0)
                         {
-                            
e.Base.ExtensionElements.Add(f.CreateInstance(node));
+                            
e.Base.ExtensionElements.Add(f.CreateInstance(node, parser));
                             e.DiscardEntry = true;
                             break;
                         }

Modified: trunk/clients/cs/src/core/atombase.cs
==============================================================================
--- trunk/clients/cs/src/core/atombase.cs       (original)
+++ trunk/clients/cs/src/core/atombase.cs       Tue Sep 18 04:59:41 2007
@@ -345,7 +345,7 @@
             IExtensionElementFactory f = FindExtensionFactory(localName, ns);
             if (f != null)
             {
-                ele = f.CreateInstance(null);
+                ele = f.CreateInstance(null, null);
             }
             return ele;
         }

Modified: trunk/clients/cs/src/core/serviceinterface.cs
==============================================================================
--- trunk/clients/cs/src/core/serviceinterface.cs       (original)
+++ trunk/clients/cs/src/core/serviceinterface.cs       Tue Sep 18 04:59:41 2007
@@ -179,7 +179,7 @@
         /// </summary>
         /// <param name="node">the xmlnode to parse</param>
         /// <returns></returns>
-        IExtensionElement CreateInstance(XmlNode node); 
+        IExtensionElement CreateInstance(XmlNode node, AtomFeedParser parser); 
     }
 
 

Modified: trunk/clients/cs/src/extensions/extensionbase.cs
==============================================================================
--- trunk/clients/cs/src/extensions/extensionbase.cs    (original)
+++ trunk/clients/cs/src/extensions/extensionbase.cs    Tue Sep 18 04:59:41 2007
@@ -104,7 +104,7 @@
         /// <param name="node">the xml parses node, can be NULL</param>
         /// <returns>the created IExtensionElement object</returns>
         //////////////////////////////////////////////////////////////////////
-        public virtual IExtensionElement CreateInstance(XmlNode node) 
+        public virtual IExtensionElement CreateInstance(XmlNode node, 
AtomFeedParser parser) 
         {
             Tracing.TraceCall();
 

Modified: trunk/clients/cs/src/extensions/reminder.cs
==============================================================================
--- trunk/clients/cs/src/extensions/reminder.cs (original)
+++ trunk/clients/cs/src/extensions/reminder.cs Tue Sep 18 04:59:41 2007
@@ -192,11 +192,11 @@
 
         #region overloaded from IExtensionElementFactory
         //////////////////////////////////////////////////////////////////////
-        /// <summary>Parses an xml node to create a Who object.</summary> 
+        /// <summary>Parses an xml node to create a Reminder object.</summary> 
         /// <param name="node">the node to parse node</param>
-        /// <returns>the created GeoRSSWhere object</returns>
+        /// <returns>the created Reminder object</returns>
         //////////////////////////////////////////////////////////////////////
-        public IExtensionElement CreateInstance(XmlNode node)
+        public IExtensionElement CreateInstance(XmlNode node, AtomFeedParser 
parser)
         {
             Tracing.TraceCall();
             Reminder reminder = null;
@@ -213,7 +213,7 @@
 
             bool absoluteFlag = false;
             reminder = new Reminder();
-            if (node.Attributes != null)
+            if (node != null && node.Attributes != null)
             {
                 if 
(node.Attributes[GDataParserNameTable.XmlAttributeAbsoluteTime] != null)
                 {

Modified: trunk/clients/cs/src/extensions/simplecontainer.cs
==============================================================================
--- trunk/clients/cs/src/extensions/simplecontainer.cs  (original)
+++ trunk/clients/cs/src/extensions/simplecontainer.cs  Tue Sep 18 04:59:41 2007
@@ -157,7 +157,7 @@
         /// <param name="node">the node to work on, can be NULL</param>
         /// <returns>the created SimpleElement object</returns>
         //////////////////////////////////////////////////////////////////////
-        public override IExtensionElement CreateInstance(XmlNode node) 
+        public override IExtensionElement CreateInstance(XmlNode node, 
AtomFeedParser parser) 
         {
             Tracing.TraceCall("for: " + XmlName);
 
@@ -187,7 +187,7 @@
                             if (String.Compare(childNode.LocalName, f.XmlName) 
== 0)
                             {
                                 Tracing.TraceMsg("Added extension to 
SimpleContainer for: " + f.XmlName);
-                                
sc.ExtensionElements.Add(f.CreateInstance(childNode));
+                                
sc.ExtensionElements.Add(f.CreateInstance(childNode, parser));
                                 break;
                             }
                         }

Modified: trunk/clients/cs/src/extensions/simpleelement.cs
==============================================================================
--- trunk/clients/cs/src/extensions/simpleelement.cs    (original)
+++ trunk/clients/cs/src/extensions/simpleelement.cs    Tue Sep 18 04:59:41 2007
@@ -77,7 +77,7 @@
         /// <summary>
         ///  Accessor Method for the value
         /// </summary>
-        public string Value
+        public virtual string Value
         {
             get { return value; }
             set { this.value = value;}
@@ -119,7 +119,7 @@
         /// <param name="node">the xml parses node, can be NULL</param>
         /// <returns>the created SimpleElement object</returns>
         //////////////////////////////////////////////////////////////////////
-        public override IExtensionElement CreateInstance(XmlNode node) 
+        public override IExtensionElement CreateInstance(XmlNode node, 
AtomFeedParser parser) 
         {
             Tracing.TraceCall();
 
@@ -161,4 +161,52 @@
         }
         #endregion
     }
+
+
+
+
+    /// <summary>
+    /// a simple element with one attribute,called value that exposes 
+    /// that value as the value property
+    /// </summary>
+    public class SimpleAttribute : SimpleElement
+    {
+        /// <summary>
+        /// constructor
+        /// </summary>
+        /// <param name="name">the xml name</param>
+        /// <param name="prefix">the xml prefix</param>
+        /// <param name="ns">the xml namespace</param>
+        protected SimpleAttribute(string name, string prefix, string ns)
+                    :base(name, prefix,ns)
+        {
+            this.Attributes.Add(BaseNameTable.XmlValue, null);
+        }
+
+
+
+        /// <summary>
+        /// constructor
+        /// </summary>
+        /// <param name="name">the xml name</param>
+        /// <param name="prefix">the xml prefix</param>
+        /// <param name="ns">the xml namespace</param>
+        /// <param name="value">the intial value</param>
+        protected SimpleAttribute(string name, string prefix, string ns, 
string value)
+                    :base(name, prefix, ns)
+        {
+            this.Attributes.Add(BaseNameTable.XmlValue, value);
+        }
+
+        //////////////////////////////////////////////////////////////////////
+        /// <summary>read only accessor</summary> 
+        /// <returns> </returns>
+        //////////////////////////////////////////////////////////////////////
+        public override string Value
+        {
+            get {return this.Attributes[BaseNameTable.XmlValue] as string;}
+        }
+        // end of accessor public string Value
+    }
+
 }  

Modified: trunk/clients/cs/src/extensions/when.cs
==============================================================================
--- trunk/clients/cs/src/extensions/when.cs     (original)
+++ trunk/clients/cs/src/extensions/when.cs     Tue Sep 18 04:59:41 2007
@@ -197,7 +197,7 @@
                         {
                             if (String.Compare(whenChildNode.LocalName, 
f.XmlName) == 0)
                             {
-                                Reminder r = f.CreateInstance(whenChildNode) 
as Reminder;
+                                Reminder r = f.CreateInstance(whenChildNode, 
null) as Reminder;
                                 when.Reminders.Add(r);
                             }
                         }

Modified: trunk/clients/cs/src/extensions/where.cs
==============================================================================
--- trunk/clients/cs/src/extensions/where.cs    (original)
+++ trunk/clients/cs/src/extensions/where.cs    Tue Sep 18 04:59:41 2007
@@ -23,9 +23,26 @@
 {
 
     /// <summary>
-    /// GData Schema describing a place or location
+    /// A place (such as an event location) associated with the containing 
entity. The type of 
+    /// the association is determined by the rel attribute; the details of the 
location are 
+    /// contained in an embedded or linked-to Contact entry.
+    /// A gd:where element is more general than a gd:geoPt element. The former 
identifies a place
+    ///  using a text description and/or a Contact entry, while the latter 
identifies a place 
+    /// using a specific geographic location.
+    ///     Properties
+    ////    Property       Type            Description
+    ///     @label?        xs:string   Specifies a user-readable label to 
distinguish this location from other locations.
+    ///     @rel?              xs:string       Specifies the relationship 
between the containing entity and the contained location. Possible values (see 
below) are defined by other elements. For example, <gd:when> defines 
http://schemas.google.com/g/2005#event.
+    ///     @valueString?      xs:string       A simple string value that can 
be used as a representation of this location.
+    ////    gd:entryLink?      entryLink       Entry representing location 
details. This entry should implement the Contact kind.
+    ///     rel values
+    ///     Value                                                          
Description
+    ////    http://schemas.google.com/g/2005#event or not specified     Place 
where the enclosing event takes place.
+    ////    http://schemas.google.com/g/2005#event.alternate             A 
secondary location. For example, a remote 
+    ///                                                                  site 
with a videoconference link to the main site.
+    ////    http://schemas.google.com/g/2005#event.parking                   A 
nearby parking lot.
     /// </summary>
-    public class Where : IExtensionElement
+    public class Where : IExtensionElement, IExtensionElementFactory
     {
 
         /// <summary>
@@ -110,45 +127,48 @@
             set { entryLink = value; }
         }
 
-        #region Where Parser
+        #region overloaded from IExtensionElementFactory
         //////////////////////////////////////////////////////////////////////
-        /// <summary>parses an xml node to create a Where object</summary> 
-        /// <param name="node">where node</param>
-        /// <param name="parser">AtomFeedParser to use</param>
-        /// <returns> the created Where object</returns>
+        /// <summary>Parses an xml node to create a Where  object.</summary> 
+        /// <param name="node">the node to parse node</param>
+        /// <returns>the created Where  object</returns>
         //////////////////////////////////////////////////////////////////////
-        public static Where ParseWhere(XmlNode node, AtomFeedParser parser)
+        public IExtensionElement CreateInstance(XmlNode node, AtomFeedParser 
parser)
         {
             Tracing.TraceCall();
             Where where = null;
-            Tracing.Assert(node != null, "node should not be null");
-            if (node == null)
+
+            if (node != null)
             {
-                throw new ArgumentNullException("node");
+                object localname = node.LocalName;
+                if (localname.Equals(this.XmlName) == false ||
+                  node.NamespaceURI.Equals(this.XmlNameSpace) == false)
+                {
+                    return null;
+                }
             }
 
-            object localname = node.LocalName;
-            if (localname.Equals(GDataParserNameTable.XmlWhereElement))
-            {
-                where = new Where();
+            where = new Where();
+            if (node != null) {
+
                 if (node.Attributes != null)
                 {
                     if (node.Attributes[GDataParserNameTable.XmlAttributeRel] 
!= null)
                     {
                         where.Rel = 
node.Attributes[GDataParserNameTable.XmlAttributeRel].Value;
                     }
-
+    
                     if 
(node.Attributes[GDataParserNameTable.XmlAttributeLabel] != null)
                     {
                         where.Label = 
node.Attributes[GDataParserNameTable.XmlAttributeLabel].Value;
                     }
-
+    
                     if 
(node.Attributes[GDataParserNameTable.XmlAttributeValueString] != null)
                     {
                         where.ValueString = 
node.Attributes[GDataParserNameTable.XmlAttributeValueString].Value;
                     }
                 }
-
+    
                 if (node.HasChildNodes)
                 {
                     foreach (XmlNode childNode in node.ChildNodes)
@@ -167,12 +187,8 @@
                     }
                 }
             }
-
             return where;
         }
-        #endregion
-
-        #region overloaded for persistence
 
         //////////////////////////////////////////////////////////////////////
         /// <summary>Returns the constant representing this XML 
element.</summary> 
@@ -182,7 +198,27 @@
             get { return GDataParserNameTable.XmlWhereElement; }
         }
 
+        //////////////////////////////////////////////////////////////////////
+        /// <summary>Returns the constant representing this XML 
element.</summary> 
+        //////////////////////////////////////////////////////////////////////
+        public string XmlNameSpace
+        {
+            get { return BaseNameTable.gNamespace; }
+        }
+
+        //////////////////////////////////////////////////////////////////////
+        /// <summary>Returns the constant representing this XML 
element.</summary> 
+        //////////////////////////////////////////////////////////////////////
+        public string XmlPrefix
+        {
+            get { return BaseNameTable.gDataPrefix; }
+        }
+
+        #endregion
+
+        #region overloaded for persistence
 
+      
         /// <summary>
         /// Persistence method for the Where object
         /// </summary>

Modified: trunk/clients/cs/src/gcalendar/calendarentry.cs
==============================================================================
--- trunk/clients/cs/src/gcalendar/calendarentry.cs     (original)
+++ trunk/clients/cs/src/gcalendar/calendarentry.cs     Tue Sep 18 04:59:41 2007
@@ -41,8 +41,8 @@
             this.AddExtension(new GCalColor());
             this.AddExtension(new GCalSelected());
             this.AddExtension(new GCalAccessLevel());
-            //this.AddExtension(new Where());
-            //this.AddExtension(new TimeZone());
+            this.AddExtension(new Where());
+            this.AddExtension(new TimeZone());
         }
 
         /// <summary>

Modified: trunk/clients/cs/src/gcalendar/evententry.cs
==============================================================================
--- trunk/clients/cs/src/gcalendar/evententry.cs        (original)
+++ trunk/clients/cs/src/gcalendar/evententry.cs        Tue Sep 18 04:59:41 2007
@@ -45,6 +45,7 @@
         : base()
         {
             Categories.Add(EVENT_CATEGORY);
+            addEventEntryExtensions();
             times = new WhenCollection(this);
             locations = new WhereCollection(this);
             participants = new WhoCollection(this);
@@ -83,8 +84,17 @@
             Where eventLocation = new Where();
             eventLocation.ValueString = location;
             this.Locations.Add(eventLocation);
+            
         }
 
+        /// <summary>
+        ///  helper method to add extensions to the evententry
+        /// </summary>
+        private void addEventEntryExtensions()
+        {
+            this.AddExtension(new Reminder());
+            this.AddExtension(new Where());
+        }
 
         /// <summary>
         /// Constructs a new EventStatus  instance
@@ -723,13 +733,7 @@
                     this.Times.Add(When.ParseWhen(eventNode));
                     e.DiscardEntry = true;
                 }
-                // Parse a Where Element
-                else if (eventNode.LocalName == 
GDataParserNameTable.XmlWhereElement)
-                {
-                    this.Locations.Add((Where.ParseWhere(eventNode, parser)));
-                    e.DiscardEntry = true;
-                }
-                // Parse a Who Element
+                 // Parse a Who Element
                 else if (eventNode.LocalName == 
GDataParserNameTable.XmlWhoElement)
                 {
                     this.Participants.Add((Who.ParseWho(eventNode, parser)));

Modified: trunk/clients/cs/src/gcalendar/eventfeed.cs
==============================================================================
--- trunk/clients/cs/src/gcalendar/eventfeed.cs (original)
+++ trunk/clients/cs/src/gcalendar/eventfeed.cs Tue Sep 18 04:59:41 2007
@@ -22,84 +22,42 @@
 
 namespace Google.GData.Calendar {
 
-    //////////////////////////////////////////////////////////////////////
-    /// <summary>holds the timezone element on the feed level
-    /// </summary> 
-    //////////////////////////////////////////////////////////////////////
-    public class TimeZone  : IExtensionElement
-    {
-        private string value; 
 
-        //////////////////////////////////////////////////////////////////////
-        /// <summary>read only accessor</summary> 
-        /// <returns> </returns>
-        //////////////////////////////////////////////////////////////////////
-        public string Value
+    /// <summary>
+    /// holds the timezone element on the feed level
+    /// </summary>
+    public class TimeZone : SimpleAttribute
+    {
+        /// <summary>
+        ///  default constructor
+        /// </summary>
+        public TimeZone()
+            : base(GDataParserNameTable.XmlTimeZoneElement, 
GDataParserNameTable.gCalPrefix, GDataParserNameTable.NSGCal)
         {
-            get {return this.value;}
         }
-        // end of accessor public string Value
 
-        //////////////////////////////////////////////////////////////////////
-        /// <summary>internal setter for parsing</summary> 
-        //////////////////////////////////////////////////////////////////////
-        internal void setTimeZone(string value) 
+        /// <summary>
+        ///  defaull constructor with an initial value for the attribute
+        /// </summary>
+        /// <param name="initValue"></param>
+        public TimeZone(string initValue)
+            : base(GDataParserNameTable.XmlTimeZoneElement, 
GDataParserNameTable.gCalPrefix, GDataParserNameTable.NSGCal, initValue)
         {
-            this.value = value; 
         }
 
-#region timezone Parser
-        //////////////////////////////////////////////////////////////////////
-        /// <summary>Parses an XML node to create a feed level 
timezone</summary> 
-        /// <param name="node">timezone node</param>
-        /// <returns> the created timezone object</returns>
-        //////////////////////////////////////////////////////////////////////
-        public static TimeZone ParseTimeZone(XmlNode node)
-        {
-            Tracing.TraceMsg("Entering ParseTimeZone");
-            TimeZone timezone = null;
-            Tracing.Assert(node != null, "node should not be null");
-
-            if (node == null)
-            {
-                throw new ArgumentNullException("node");
-            }
-
-            object localname = node.LocalName;
-            if (localname.Equals(GDataParserNameTable.XmlTimeZoneElement))
-            {
-                timezone = new TimeZone();
-                if (node.Attributes != null)
-                {
-                    if (node.Attributes[GDataParserNameTable.XmlValue] != null)
-                    {
-                        
timezone.setTimeZone(node.Attributes[GDataParserNameTable.XmlValue].Value); 
-                    }
-                }
-            }
-
-            return timezone;
-        }
-
-
         //////////////////////////////////////////////////////////////////////
         /// <summary>saves the current object into the stream. TimeZone,
         /// though does not get saved</summary> 
         /// <param name="writer">xmlWriter to write into</param>
         //////////////////////////////////////////////////////////////////////
-        public void Save(XmlWriter writer)
+        public override void Save(XmlWriter writer)
         {
             Tracing.TraceMsg("Save called on TimeZone... skipping it"); 
             return; 
         }
-
-#endregion
-
-
-
     }
-    //end of public class TimeZone
 
+    
     //////////////////////////////////////////////////////////////////////
     /// <summary>
     /// Feed API customization class for defining feeds in an Event feed.
@@ -108,7 +66,6 @@
     public class EventFeed : AbstractFeed
     {
 
-        private Where location;
         private TimeZone timezone; 
 
         /// <summary>
@@ -119,6 +76,8 @@
         public EventFeed(Uri uriBase, IService iService) : base(uriBase, 
iService)
         {
             AddExtension(new WebContent());
+            AddExtension(new Where());
+            AddExtension(new TimeZone());
         }
 
 
@@ -127,15 +86,17 @@
         //////////////////////////////////////////////////////////////////////
         public Where Location
         {
-            get { return location;}
+            get 
+            { 
+
+                return FindExtension(GDataParserNameTable.XmlWhereElement, 
+                                     BaseNameTable.gNamespace) as Where;
+            }
             set
             {
-                if (location != null)
-                {
-                    ExtensionElements.Remove(location);
-                }
-                location = value;
-                ExtensionElements.Add(location);
+                ReplaceExtension(GDataParserNameTable.XmlWhereElement, 
+                                 BaseNameTable.gNamespace,
+                                 value);
             }
         }
 
@@ -145,8 +106,18 @@
         //////////////////////////////////////////////////////////////////////
         public TimeZone TimeZone
         {
-            get {return this.timezone;}
-            set {this.timezone = value;}
+            get 
+            { 
+
+                return FindExtension(GDataParserNameTable.XmlTimeZoneElement, 
+                                     GDataParserNameTable.NSGCal) as TimeZone;
+            }
+            set
+            {
+                ReplaceExtension(GDataParserNameTable.XmlTimeZoneElement, 
+                                 GDataParserNameTable.NSGCal,
+                                 value);
+            }
         }
         // end of accessor public TimeZone TimeZone
 
@@ -187,30 +158,7 @@
         }
 
 
-        //////////////////////////////////////////////////////////////////////
-        /// <summary>Parses the inner state of the element.</summary>
-        /// <param name="eventNode">a g-scheme, xml node</param>
-        /// <param name="parser">AtomFeedParser to use</param>
-        //////////////////////////////////////////////////////////////////////
-        public void parseEvent(XmlNode eventNode, AtomFeedParser parser)
-        {
-            if (String.Compare(eventNode.NamespaceURI, 
BaseNameTable.gNamespace, true) == 0)
-            {
-                // Parse a Where Element
-                if (eventNode.LocalName == 
GDataParserNameTable.XmlWhereElement)
-                {
-                    if (this.Location == null)
-                    {
-                        this.Location = Where.ParseWhere(eventNode, parser);
-                    }
-                    else
-                    {
-                        throw new ArgumentException("Only one g:where element 
is valid in the Event Feeds");
-                    }
-                }
-            }
-        }
-
+      
         /// <summary>
         /// this needs to get implemented by subclasses
         /// </summary>
@@ -226,7 +174,8 @@
         /// get's called after we already handled the custom entry, to handle 
all 
         /// other potential parsing tasks
         /// </summary>
-        /// <param name="e"></param>
        /// <param name="parser">the atom feed parser used</param>
+        /// <param name="e">the element throwing the event</param>
+        /// <param name="parser">the atom feed parser used</param>
         protected override void 
HandleExtensionElements(ExtensionElementEventArgs e, AtomFeedParser parser)
         {
             Tracing.TraceMsg("\t HandleExtensionElements for CalendarFeed 
called");
@@ -235,35 +184,11 @@
 
             if (String.Compare(e.ExtensionElement.NamespaceURI, 
BaseNameTable.gNamespace, true) == 0)
             {
-                // found GD namespace
-               if (e.Base.XmlName == AtomParserNameTable.XmlFeedElement)
-                {
-                    EventFeed eventFeed = e.Base as EventFeed;
-                    if (eventFeed != null)
-                    {
-                        eventFeed.parseEvent(e.ExtensionElement, parser);
-                        e.DiscardEntry = true;
-                    }
-                }
-                else if (e.ExtensionElement.LocalName == 
GDataParserNameTable.XmlExtendedPropertyElement)
+                if (e.ExtensionElement.LocalName == 
GDataParserNameTable.XmlExtendedPropertyElement)
                 {
                     ExtendedProperty prop = 
ExtendedProperty.Parse(e.ExtensionElement); 
                     e.Base.ExtensionElements.Add(prop); 
                     e.DiscardEntry = true;
-                }
-            }
-            else if (String.Compare(e.ExtensionElement.NamespaceURI, 
GDataParserNameTable.NSGCal, true) == 0)
-            {
-                // found calendar  namespace
-                Tracing.TraceMsg("\t entering the handler for calendar 
specific extensions for: " + e.Base.XmlName);
-                if (e.ExtensionElement.LocalName == 
GDataParserNameTable.XmlTimeZoneElement)
-                {
-                    EventFeed eventFeed = e.Base as EventFeed;
-                    if (eventFeed != null)
-                    {
-                        eventFeed.TimeZone = 
TimeZone.ParseTimeZone(e.ExtensionElement);
-                        e.DiscardEntry = true;
-                    }
                 }
             }
         }

Modified: trunk/clients/cs/src/gcalendar/webcontent.cs
==============================================================================
--- trunk/clients/cs/src/gcalendar/webcontent.cs        (original)
+++ trunk/clients/cs/src/gcalendar/webcontent.cs        Tue Sep 18 04:59:41 2007
@@ -90,7 +90,7 @@
         /// <param name="node">xml node</param>
         /// <returns>the created SimpleElement object</returns>
         //////////////////////////////////////////////////////////////////////
-        public IExtensionElement CreateInstance(XmlNode node) 
+        public IExtensionElement CreateInstance(XmlNode node, AtomFeedParser 
parser) 
         {
             Tracing.TraceCall();
 

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Data API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/google-help-dataapi?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to