internal CanonicalXml(XmlDocument document, XmlResolver resolver, bool includeComments) { if (document == null) { throw new ArgumentNullException(nameof(document)); } m_c14nDoc = new CanonicalXmlDocument(true, includeComments); m_c14nDoc.XmlResolver = resolver; m_c14nDoc.Load(new XmlNodeReader(document)); m_ancMgr = new C14NAncestralNamespaceContextManager(); }
internal CanonicalXml( Stream inputStream, bool includeComments, XmlResolver resolver, string strBaseUri) { if (inputStream == null) { throw new ArgumentNullException(nameof(inputStream)); } m_c14nDoc = new CanonicalXmlDocument(true, includeComments); m_c14nDoc.XmlResolver = resolver; m_c14nDoc.Load(PreProcessStreamInput(inputStream, resolver, strBaseUri)); m_ancMgr = new C14NAncestralNamespaceContextManager(); }
internal ExcCanonicalXml( XmlDocument document, bool includeComments, string inclusiveNamespacesPrefixList, XmlResolver resolver) { if (document == null) { throw new ArgumentNullException(nameof(document)); } this.m_c14nDoc = new CanonicalXmlDocument(true, includeComments); this.m_c14nDoc.XmlResolver = resolver; this.m_c14nDoc.Load((XmlReader) new XmlNodeReader((XmlNode)document)); this.m_ancMgr = new ExcAncestralNamespaceContextManager(inclusiveNamespacesPrefixList); }
internal ExcCanonicalXml( Stream inputStream, bool includeComments, string inclusiveNamespacesPrefixList, XmlResolver resolver, string strBaseUri) { if (inputStream == null) { throw new ArgumentNullException(nameof(inputStream)); } this.m_c14nDoc = new CanonicalXmlDocument(true, includeComments); this.m_c14nDoc.XmlResolver = resolver; this.m_c14nDoc.Load(Exml.PreProcessStreamInput(inputStream, resolver, strBaseUri)); this.m_ancMgr = new ExcAncestralNamespaceContextManager(inclusiveNamespacesPrefixList); }
internal CanonicalXml(XmlNodeList nodeList, XmlResolver resolver, bool includeComments) { if (nodeList == null) { throw new ArgumentNullException(nameof(nodeList)); } XmlDocument ownerDocument = Exml.GetOwnerDocument(nodeList); if (ownerDocument == null) { throw new ArgumentException(nameof(nodeList)); } m_c14nDoc = new CanonicalXmlDocument(false, includeComments); m_c14nDoc.XmlResolver = resolver; m_c14nDoc.Load(new XmlNodeReader(ownerDocument)); m_ancMgr = new C14NAncestralNamespaceContextManager(); MarkInclusionStateForNodes(nodeList, ownerDocument, m_c14nDoc); }
internal ExcCanonicalXml( XmlNodeList nodeList, bool includeComments, string inclusiveNamespacesPrefixList, XmlResolver resolver) { if (nodeList == null) { throw new ArgumentNullException(nameof(nodeList)); } XmlDocument ownerDocument = Exml.GetOwnerDocument(nodeList); if (ownerDocument == null) { throw new ArgumentException(nameof(nodeList)); } this.m_c14nDoc = new CanonicalXmlDocument(false, includeComments); this.m_c14nDoc.XmlResolver = resolver; this.m_c14nDoc.Load((XmlReader) new XmlNodeReader((XmlNode)ownerDocument)); this.m_ancMgr = new ExcAncestralNamespaceContextManager(inclusiveNamespacesPrefixList); ExcCanonicalXml.MarkInclusionStateForNodes(nodeList, ownerDocument, (XmlDocument)this.m_c14nDoc); }