コード例 #1
0
        protected override DateTime OnGetDateTime(int index)
        {
            DateTime returnValue = DateTime.MinValue;

            EasterSundayCalculator easterSundayCalculator = new EasterSundayCalculator(DateTime.Now.Year + (int)index);

            returnValue = easterSundayCalculator.Date.Subtract(TimeSpan.FromDays(2));

            return(returnValue);
        }
コード例 #2
0
        protected override DateTime OnGetDateTime(int index)
        {
            DateTime returnValue = DateTime.MinValue;

            //
            // Returns the full date and time of
            // nth occurrence of this time. The value
            // 0 always returns the 'next' occurrence
            // and has the same value as the NextDateTime
            // property.
            //
            EasterSundayCalculator easterSundayCalculator = new EasterSundayCalculator(DateTime.Now.Year + (int)index);

            returnValue = easterSundayCalculator.Date;

            return(returnValue);
        }