Ejemplo n.º 1
0
 /// <summary>
 /// Determines whether the specified eligibility codes contains code.
 /// </summary>
 /// <param name="eligibilityCodes">The eligibility codes.</param>
 /// <param name="candidate">The candidate.</param>
 /// <returns>
 ///   <c>true</c> if the specified eligibility codes contains code; otherwise, <c>false</c>.
 /// </returns>
 public bool ContainsCode(IContainThis <string> eligibilityCodes, string candidate) =>
 eligibilityCodes.Contains(candidate);
 /// <summary>
 /// Determines whether [has any qualifying eligibility] [the specified delivery].
 /// </summary>
 /// <param name="delivery">The delivery.</param>
 /// <param name="postcodes">The postcodes.</param>
 /// <param name="eligibilityCodes">The eligibility codes.</param>
 /// <returns>
 ///   <c>true</c> if [has any qualifying eligibility] [the specified delivery]; otherwise, <c>false</c>.
 /// </returns>
 public override bool HasAnyQualifyingEligibility(ILearningDelivery delivery, IReadOnlyCollection <IONSPostcode> postcodes, IContainThis <string> eligibilityCodes) =>
 postcodes.Any(x => eligibilityCodes.Contains(x.LocalAuthority) && InQualifyingPeriod(delivery, x));