SanderVantEinde.WindesheimRoosterBot.Rooster.GetLesForTime C# (CSharp) Method

GetLesForTime() public method

public GetLesForTime ( System.DateTime time, string ignoredLessen = null ) : Les
time System.DateTime
ignoredLessen string
return Les
        public Les GetLesForTime(DateTime time, string[] ignoredLessen = null)
        {
            foreach (Les l in Lessen)
                if (l.StartTime <= time && l.EndTime >= time && (ignoredLessen == null || !ignoredLessen.Contains(l.Omschrijving)))
                    return l;
            return null;
        }
        public Les GetFirstLesAfterTime(DateTime time, string[] ignoredLessen = null)