you analysis is correct, i will change findextensions though differently. I don't like creating a new array just to figure out that nothing is there. So i probably if (something there) ... the case.
Frank Mantek Google On Oct 9, 2007, at 9:16 AM, Kulvinder Singh wrote: > Afetr i corrected the problem, i tried to cretae a deleted > recurrence exception and got the following error : > > > org.xml.sax.SAXParseException: Element type "http:" must > be followed by either attribute specifications, ">" or > "/>". > > Now what does that mean ? > > I am using Google API 1.1.0.0 with no other modifications. Where is > the problem now ? > > Seems like that the new API release changes have not been tested > properly. > > I seem to be harsh but it seems to have shaken my trust on the > credibility of the releases > > Thanks > Kulvinder Singh > ----- Original Message ---- > From: Kulvinder Singh <[EMAIL PROTECTED]> > To: Google API <[email protected]> > Sent: Tuesday, October 9, 2007 12:36:35 PM > Subject: 3rd Major bug in new Google API 1.1.0.0 > > Hi, > > In the series of bugs in new calendar .NET API 1.1.0.0, there is > another bug and i found it through the following : > > I am trying to add an exception in a Google Event as follows : > > OriginalEvent originalEvent = new OriginalEvent(); > > originalEvent.OriginalStartTime = originalWhen; > > originalEvent.Href = selfURIContent; > > originalEvent.IdOriginal = Common.GetGcalEventSubID(selfURIContent); > > gCalExceptionEvent.OriginalEvent = originalEvent; > > > As soon as i executed my code, it threw an exception at : > originalEvent.OriginalStartTime > > > which is > > > ////////////////////////////////////////////////////////////////////// > > /// <summary>accessor method public original Start Time</summary> > > /// <returns> </returns> > > ////////////////////////////////////////////////////////////////////// > > public When OriginalStartTime > > { > > get > > { > > return FindExtension(GDataParserNameTable.XmlWhenElement, > > BaseNameTable.gNamespace) as When; > > } > > set > > { > > ReplaceExtension(GDataParserNameTable.XmlWhenElement, > > BaseNameTable.gNamespace, value); > > } > > } > > > and > > > public void ReplaceExtension(string localName, string ns, Object obj) > > { > > DeleteExtensions(localName, ns); > > this.ExtensionElements.Add(obj); > > } > > > > /// <summary> > > /// Delete's all Extensions from the Extension list that match > > /// a localName and a Namespace. > > /// </summary> > > /// <param name="localName">the local name to find</param> > > /// <param name="ns">the namespace to match, if null, ns is > ignored</param> > > /// <returns>int - the number of deleted extensions</returns> > > public int DeleteExtensions(string localName, string ns) > > { > > // Find them first > > ArrayList arr = FindExtensions(localName, ns); > > foreach (object ob in arr) > > { > > this.extensions.Remove(ob); > > } > > return arr.Count; > > } > > > > basically, the erros is being thrown by FindExtensiosn method since > it uses this.extensions which is null > > > /// <summary> > > /// Finds all ExtensionElement based on it's local name > > /// and it's namespace. If namespace is NULL, allwhere > > /// the localname matches is found. If there are extensionelements > that do > > /// not implment ExtensionElementFactory, they will not be taken > into account > > /// Primary use of this is to find XML nodes > > /// </summary> > > /// <param name="localName">the xml local name of the element to > find</param> > > /// <param name="ns">the namespace of the elementToPersist</param> > > /// <returns>none</returns> > > public ArrayList FindExtensions(string localName, string ns) > > { > > return Utilities.FindExtensions(this.extensions, localName, ns, new > ArrayList()); > > } > > > I think that instead of using this.extensions directly, it should > have been : > > > ////////////////////////////////////////////////////////////////////// > > /// <summary>the list of extensions for this container > > /// the elements in that list MUST implement IExtensionElementFactory > > /// and IExtensionElement</summary> > > /// <returns> </returns> > > ////////////////////////////////////////////////////////////////////// > > public ArrayList ExtensionElements > > { > > get > > { > > if (this.extensions == null) > > { > > this.extensions = new ArrayList(); > > } > > return this.extensions; > > } > > set { this.extensions = value; } > > } > > > so that the function FindExtensions look like : > > > > /// <summary> > > /// Finds all ExtensionElement based on it's local name > > /// and it's namespace. If namespace is NULL, allwhere > > /// the localname matches is found. If there are extensionelements > that do > > /// not implment ExtensionElementFactory, they will not be taken > into account > > /// Primary use of this is to find XML nodes > > /// </summary> > > /// <param name="localName">the xml local name of the element to > find</param> > > /// <param name="ns">the namespace of the elementToPersist</param> > > /// <returns>none</returns> > > public ArrayList FindExtensions(string localName, string ns) > > { > > return Utilities.FindExtensions(ExtensionElements, localName, ns, > new ArrayList()); > > } > > > > Please correct me if i am wrong somewhere. > > > Thanks > > Kulvinder Singh > > > Don't let your dream ride pass you by. Make it a reality with > Yahoo! Autos. > > > Be a better Heartthrob. Get better relationship answers from > someone who knows. > Yahoo! Answers - Check it out. > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Calendar 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-calendar-help-dataapi?hl=en -~----------~----~----~----~------~----~------~--~---
