Microsoft.Xades.SignatureProductionPlace.GetXml C# (CSharp) Метод

GetXml() публичный Метод

Returns the XML representation of the this object
public GetXml ( ) : XmlElement
Результат System.Xml.XmlElement
		public XmlElement GetXml()
		{
			XmlDocument creationXmlDocument;
			XmlElement retVal;
			XmlElement bufferXmlElement;

			creationXmlDocument = new XmlDocument();
			retVal = creationXmlDocument.CreateElement("SignatureProductionPlace", XadesSignedXml.XadesNamespaceUri);

			if (!String.IsNullOrEmpty(this.city))
			{
				bufferXmlElement = creationXmlDocument.CreateElement("City", XadesSignedXml.XadesNamespaceUri);
				bufferXmlElement.InnerText = this.city;
				retVal.AppendChild(bufferXmlElement);
			}

			if (!String.IsNullOrEmpty(this.stateOrProvince))
			{
				bufferXmlElement = creationXmlDocument.CreateElement("StateOrProvince", XadesSignedXml.XadesNamespaceUri);
				bufferXmlElement.InnerText = this.stateOrProvince;
				retVal.AppendChild(bufferXmlElement);
			}

			if (!String.IsNullOrEmpty(this.postalCode))
			{
				bufferXmlElement = creationXmlDocument.CreateElement("PostalCode", XadesSignedXml.XadesNamespaceUri);
				bufferXmlElement.InnerText = this.postalCode;
				retVal.AppendChild(bufferXmlElement);
			}

			if (this.countryName != null && this.countryName != "")
			{
				bufferXmlElement = creationXmlDocument.CreateElement("CountryName", XadesSignedXml.XadesNamespaceUri);
				bufferXmlElement.InnerText = this.countryName;
				retVal.AppendChild(bufferXmlElement);
			}

			return retVal;
		}
		#endregion