ToIso8601Interval() public static method

Converts a TimeInterval as an ISO8601 interval string.
public static ToIso8601Interval ( JulianDate start, JulianDate stop, Iso8601Format format ) : string
start JulianDate The start of the interval.
stop JulianDate The end of the interval.
format Iso8601Format The format to use.
return string
コード例 #1
0
        /// <summary>
        /// Writes the actual interval of time covered by this CZML interval.
        /// </summary>
        /// <param name="interval">The interval.</param>
        public void WriteInterval([NotNull] TimeInterval interval)
        {
            if (interval == null)
            {
                throw new ArgumentNullException("interval");
            }

            OpenIntervalIfNecessary();
            Output.WritePropertyName("interval");
            Output.WriteValue(CesiumFormattingHelper.ToIso8601Interval(interval.Start, interval.Stop, Output.PrettyFormatting ? Iso8601Format.Extended : Iso8601Format.Compact));
        }
コード例 #2
0
 /// <summary>
 /// Writes the actual interval of time covered by this CZML interval.
 /// </summary>
 /// <param name="interval">The interval.</param>
 public void WriteInterval(TimeInterval interval)
 {
     OpenIntervalIfNecessary();
     Output.WritePropertyName("interval");
     Output.WriteValue(CesiumFormattingHelper.ToIso8601Interval(interval.Start, interval.Stop, Output.PrettyFormatting ? Iso8601Format.Extended : Iso8601Format.Compact));
 }
コード例 #3
0
 /// <summary>
 /// Writes a <see cref="TimeInterval"/> as an ISO 8601 interval string.
 /// </summary>
 /// <param name="output">The stream to which to write the value.</param>
 /// <param name="interval">The interval to write.</param>
 public static void WriteTimeInterval(CesiumOutputStream output, TimeInterval interval)
 {
     output.WriteValue(CesiumFormattingHelper.ToIso8601Interval(interval.Start, interval.Stop, output.PrettyFormatting ? Iso8601Format.Extended : Iso8601Format.Compact));
 }