public void AddReference(XmlName xmlName, Type xmlObjectType) { if ((object)xmlName == null) throw new ArgumentNullException("xmlName"); if ((object)xmlObjectType == null) throw new ArgumentNullException("xmlObjectType"); this.Xpe.RegisterKnownXmlObject(xmlName, xmlObjectType); }
/// <summary> /// Performs a custom equals test against two XML name objects using value semantics over the local name and namespace URI. /// </summary> /// <param name="a"> The first XML name to test. </param> /// <param name="b"> The second XML name object to test. </param> /// <returns> A value indicating whther the two XML name objects are equal using value semantics. </returns> private static bool TestEquals(XmlName a, XmlName b) { return (a.LocalName == b.LocalName) && (a.NamespaceUri == b.NamespaceUri); }