void ThrowIfElementIsXOPInclude(string prefix, string localName, string ns) { if (ns == null) { XmlBaseWriter w = this.Writer as XmlBaseWriter; if (w != null) ns = w.LookupNamespace(prefix); } if (localName == MtomGlobals.XopIncludeLocalName && ns == MtomGlobals.XopIncludeNamespace) throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new XmlException(SR.GetString(SR.MtomDataMustNotContainXopInclude, MtomGlobals.XopIncludeLocalName, MtomGlobals.XopIncludeNamespace))); }
private void ThrowIfElementIsXOPInclude(string prefix, string localName, string ns) { if (ns == null) { XmlBaseWriter writer = this.Writer as XmlBaseWriter; if (writer != null) { ns = writer.LookupNamespace(prefix); } } if ((localName == MtomGlobals.XopIncludeLocalName) && (ns == MtomGlobals.XopIncludeNamespace)) { throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new XmlException(System.Runtime.Serialization.SR.GetString("MtomDataMustNotContainXopInclude", new object[] { MtomGlobals.XopIncludeLocalName, MtomGlobals.XopIncludeNamespace }))); } }