コード例 #1
0
        private TimeZoneDefinition.Transition ConvertTransition(TransitionType transitionType)
        {
            TimeZoneDefinition.TransitionTargetType to            = new TimeZoneDefinition.TransitionTargetType(this.ConvertTransitionKind(transitionType.To.Kind), transitionType.To.Value);
            AbsoluteDateTransitionType absoluteDateTransitionType = transitionType as AbsoluteDateTransitionType;

            if (absoluteDateTransitionType != null)
            {
                return(new TimeZoneDefinition.AbsoluteDateTransition(to, absoluteDateTransitionType.DateTime));
            }
            RecurringDayTransitionType recurringDayTransitionType = transitionType as RecurringDayTransitionType;

            if (recurringDayTransitionType != null)
            {
                return(new TimeZoneDefinition.RecurringDayTransition(to, recurringDayTransitionType.TimeOffset, recurringDayTransitionType.Month, recurringDayTransitionType.DayOfWeek, recurringDayTransitionType.Occurrence));
            }
            RecurringDateTransitionType recurringDateTransitionType = transitionType as RecurringDateTransitionType;

            if (recurringDateTransitionType != null)
            {
                return(new TimeZoneDefinition.RecurringDateTransition(to, recurringDateTransitionType.TimeOffset, recurringDateTransitionType.Month, recurringDateTransitionType.Day));
            }
            return(new TimeZoneDefinition.Transition(to));
        }
コード例 #2
0
 public RecurringDateTransition(TimeZoneDefinition.TransitionTargetType to, string timeOffset, int month, int day) : base(to, timeOffset, month)
 {
     this.day = day;
 }
コード例 #3
0
 public RecurringDayTransition(TimeZoneDefinition.TransitionTargetType to, string timeOffset, int month, string dayOfWeek, int occurrence) : base(to, timeOffset, month)
 {
     this.dayOfWeek  = dayOfWeek;
     this.occurrence = occurrence;
 }
コード例 #4
0
 public RecurringTimeTransitionType(TimeZoneDefinition.TransitionTargetType to, string timeOffset, int month) : base(to)
 {
     this.timeOffset = timeOffset;
     this.month      = month;
 }
コード例 #5
0
 public AbsoluteDateTransition(TimeZoneDefinition.TransitionTargetType to, DateTime dateTime) : base(to)
 {
     this.dateTime = dateTime;
 }
コード例 #6
0
 public Transition(TimeZoneDefinition.TransitionTargetType to)
 {
     this.to = to;
 }