Class that contains a collection of CRL references
        /// <summary>
        /// Load state from an XML element
        /// </summary>
        /// <param name="xmlElement">XML element containing new state</param>
        public void LoadXml(System.Xml.XmlElement xmlElement)
        {
            XmlNamespaceManager xmlNamespaceManager;
            XmlNodeList         xmlNodeList;

            if (xmlElement == null)
            {
                throw new ArgumentNullException("xmlElement");
            }
            if (xmlElement.HasAttribute("Id"))
            {
                this.id = xmlElement.GetAttribute("Id");
            }
            else
            {
                this.id = "";
            }

            xmlNamespaceManager = new XmlNamespaceManager(xmlElement.OwnerDocument.NameTable);
            xmlNamespaceManager.AddNamespace("xsd", XadesSignedXml.XadesNamespaceUri);

            xmlNodeList = xmlElement.SelectNodes("xsd:CRLRefs", xmlNamespaceManager);
            if (xmlNodeList.Count != 0)
            {
                this.crlRefs = new CRLRefs();
                this.crlRefs.LoadXml((XmlElement)xmlNodeList.Item(0));
            }
            xmlNodeList = xmlElement.SelectNodes("xsd:OCSPRefs", xmlNamespaceManager);
            if (xmlNodeList.Count != 0)
            {
                this.ocspRefs = new OCSPRefs();
                this.ocspRefs.LoadXml((XmlElement)xmlNodeList.Item(0));
            }
            xmlNodeList = xmlElement.SelectNodes("xsd:OtherRefs", xmlNamespaceManager);
            if (xmlNodeList.Count != 0)
            {
                this.otherRefs = new OtherRefs();
                this.otherRefs.LoadXml((XmlElement)xmlNodeList.Item(0));
            }
        }
Example #2
0
		/// <summary>
		/// Load state from an XML element
		/// </summary>
		/// <param name="xmlElement">XML element containing new state</param>
		public void LoadXml(System.Xml.XmlElement xmlElement)
		{
			XmlNamespaceManager xmlNamespaceManager;
			XmlNodeList xmlNodeList;
			
			if (xmlElement == null)
			{
				throw new ArgumentNullException("xmlElement");
			}
			if (xmlElement.HasAttribute("Id"))
			{
				this.id = xmlElement.GetAttribute("Id");
			}
			else
			{
				this.id = "";
			}

			xmlNamespaceManager = new XmlNamespaceManager(xmlElement.OwnerDocument.NameTable);
			xmlNamespaceManager.AddNamespace("xsd", XadesSignedXml.XadesNamespaceUri);

			xmlNodeList = xmlElement.SelectNodes("xsd:CRLRefs", xmlNamespaceManager);
			if (xmlNodeList.Count != 0)
			{
				this.crlRefs = new CRLRefs();
				this.crlRefs.LoadXml((XmlElement)xmlNodeList.Item(0));
			}
			xmlNodeList = xmlElement.SelectNodes("xsd:OCSPRefs", xmlNamespaceManager);
			if (xmlNodeList.Count != 0)
			{
				this.ocspRefs = new OCSPRefs();
				this.ocspRefs.LoadXml((XmlElement)xmlNodeList.Item(0));
			}
			xmlNodeList = xmlElement.SelectNodes("xsd:OtherRefs", xmlNamespaceManager);
			if (xmlNodeList.Count != 0)
			{
				this.otherRefs = new OtherRefs();
				this.otherRefs.LoadXml((XmlElement)xmlNodeList.Item(0));
			}
		}
Example #3
0
		/// <summary>
		/// Default constructor
		/// </summary>
		public CompleteRevocationRefs()
		{
			this.crlRefs = new CRLRefs();
			this.ocspRefs = new OCSPRefs();
			this.otherRefs = new OtherRefs();
		}
 /// <summary>
 /// Default constructor
 /// </summary>
 public CompleteRevocationRefs()
 {
     this.crlRefs   = new CRLRefs();
     this.ocspRefs  = new OCSPRefs();
     this.otherRefs = new OtherRefs();
 }