System.DateTimeExtensions.GetWeekLastDay C# (CSharp) Méthode

GetWeekLastDay() public static méthode

public static GetWeekLastDay ( this date ) : System.DateTime
date this
Résultat System.DateTime
		public static DateTime GetWeekLastDay(this DateTime date)
		{
			int saturdayDifference = 6 - (int) date.DayOfWeek;
			return date.AddDays(saturdayDifference).Date;
		}