예제 #1
0
 /// <summary>
 /// Writes to XML.
 /// </summary>
 /// <param name="writer">The writer.</param>
 /// <param name="xmlElementName">Name of the XML element.</param>
 internal void WriteToXml(EwsServiceXmlWriter writer, string xmlElementName)
 {
     TimeWindow.WriteToXml(
         writer,
         xmlElementName,
         this.StartTime,
         this.EndTime);
 }
예제 #2
0
        /// <summary>
        /// Writes to XML without scoping the dates and without emitting times.
        /// </summary>
        /// <param name="writer">The writer.</param>
        /// <param name="xmlElementName">Name of the XML element.</param>
        internal void WriteToXmlUnscopedDatesOnly(EwsServiceXmlWriter writer, string xmlElementName)
        {
            const string DateOnlyFormat = "yyyy-MM-ddT00:00:00";

            TimeWindow.WriteToXml(
                writer,
                xmlElementName,
                this.StartTime.ToString(DateOnlyFormat, CultureInfo.InvariantCulture),
                this.EndTime.ToString(DateOnlyFormat, CultureInfo.InvariantCulture));
        }