示例#1
0
        // Token: 0x0600076A RID: 1898 RVA: 0x0002933C File Offset: 0x0002753C
        private void WritePropertyValue(TimeSpan value, CalendarValueType valueType, CalendarValueSeparators separator)
        {
            string value2;

            if (CalendarValueType.Duration == valueType)
            {
                value2 = CalendarCommon.FormatDuration(value);
            }
            else
            {
                if (CalendarValueType.UtcOffset != valueType)
                {
                    throw new ArgumentOutOfRangeException("valueType");
                }
                if (value.Days > 0 && this.validate)
                {
                    throw new ArgumentException(CalendarStrings.UtcOffsetTimespanCannotContainDays, "value");
                }
                value2 = CalendarCommon.FormatUtcOffset(value);
            }
            this.WritePropertyValue(value2, separator);
        }