Beispiel #1
0
        /// <summary>
        /// XML fragment representation of this object
        /// </summary>
        /// <returns>XML fragment for this object.</returns>
        /// <remarks>
        /// Name for outer tag expected to be set by calling method.
        /// This fragment returns inner properties representation only
        /// </remarks>


        protected internal String ToXMLFragment()
        {
            StringBuilder xml = new StringBuilder();

            if (IsSetInstanceId())
            {
                xml.Append("<InstanceId>");
                xml.Append(EscapeXML(this.InstanceId));
                xml.Append("</InstanceId>");
            }
            if (IsSetBundleId())
            {
                xml.Append("<BundleId>");
                xml.Append(EscapeXML(this.BundleId));
                xml.Append("</BundleId>");
            }
            if (IsSetBundleState())
            {
                xml.Append("<BundleState>");
                xml.Append(EscapeXML(this.BundleState));
                xml.Append("</BundleState>");
            }
            if (IsSetStartTime())
            {
                xml.Append("<StartTime>");
                xml.Append(EscapeXML(this.StartTime));
                xml.Append("</StartTime>");
            }
            if (IsSetUpdateTime())
            {
                xml.Append("<UpdateTime>");
                xml.Append(EscapeXML(this.UpdateTime));
                xml.Append("</UpdateTime>");
            }
            if (IsSetStorage())
            {
                Storage storage = this.Storage;
                xml.Append("<Storage>");
                xml.Append(storage.ToXMLFragment());
                xml.Append("</Storage>");
            }
            if (IsSetProgress())
            {
                xml.Append("<Progress>");
                xml.Append(EscapeXML(this.Progress));
                xml.Append("</Progress>");
            }
            if (IsSetBundleTaskError())
            {
                BundleTaskError bundleTaskError = this.BundleTaskError;
                xml.Append("<BundleTaskError>");
                xml.Append(bundleTaskError.ToXMLFragment());
                xml.Append("</BundleTaskError>");
            }
            return(xml.ToString());
        }
Beispiel #2
0
 /// <summary>
 /// Sets the BundleTaskError property
 /// </summary>
 /// <param name="bundleTaskError">If the task fails, a description of the error.</param>
 /// <returns>this instance</returns>
 public BundleTask WithBundleTaskError(BundleTaskError bundleTaskError)
 {
     this.bundleTaskErrorField = bundleTaskError;
     return(this);
 }
Beispiel #3
0
 /// <summary>
 /// Sets the BundleTaskError property
 /// </summary>
 /// <param name="bundleTaskError">BundleTaskError property</param>
 /// <returns>this instance</returns>
 public BundleTask WithBundleTaskError(BundleTaskError bundleTaskError)
 {
     this.bundleTaskErrorField = bundleTaskError;
     return this;
 }