示例#1
0
        public static DayRange[] DaysToDayRanges(DateTime[] days)
        {
            DayRange[] ranges = new DayRange[days.Length];
            for (int x = 0; x < days.Length; x++) {
                DayRange dr = new DayRange();
                dr.Start = DateTimeUtil.GetStartOfDay(days[x]);
                dr.End = DateTimeUtil.GetEndOfDay(days[x]);
                ranges[x] = dr;
            }

            return ranges;
        }
示例#2
0
        public static   DayRange[] DaysToDayRanges(DateTime[] days)
        {
            DayRange[] ranges = new DayRange[days.Length];
            for (int x = 0; x < days.Length; x++)
            {
                DayRange dr = new DayRange();
                dr.Start  = DateTimeUtil.GetStartOfDay(days[x]);
                dr.End    = DateTimeUtil.GetEndOfDay(days[x]);
                ranges[x] = dr;
            }

            return(ranges);
        }