public string Format(Date date) { if (DateFormatter.IsToday(date)) { return(DateFormatter.Format(date, DateFormatter.Template.Time)); } else if (DateFormatter.IsYesterday(date)) { return(GetString(Resource.String.date_header_yesterday)); } else if (DateFormatter.IsCurrentYear(date)) { return(DateFormatter.Format(date, DateFormatter.Template.StringDayMonth)); } else { return(DateFormatter.Format(date, DateFormatter.Template.StringDayMonthYear)); } }