/// <summary>
 /// Keeps repeating the computation until it fails or the predicate returns true
 /// </summary>
 /// <param name="ma">Computation to repeat</param>
 /// <param name="schedule">Scheduler strategy for repeating</param>
 /// <typeparam name="A">Computation bound value type</typeparam>
 /// <returns>The result of the last invocation of ma</returns>
 public static Aff <A> RepeatUntil <A>(this Aff <A> ma, Schedule schedule, Func <A, bool> predicate) =>
 ScheduleAff <A> .RepeatUntil(ma, schedule, predicate);
Exemple #2
0
 /// <summary>
 /// Keeps repeating the computation until it fails or the predicate returns true
 /// </summary>
 /// <param name="ma">Computation to repeat</param>
 /// <typeparam name="RT">Runtime</typeparam>
 /// <typeparam name="A">Computation bound value type</typeparam>
 /// <returns>The result of the last invocation of ma</returns>
 public static Aff <A> repeatUntil <A>(Aff <A> ma, Func <A, bool> predicate) =>
 ScheduleAff <A> .RepeatUntil(ma, Schedule.Forever, predicate);
 /// <summary>
 /// Keeps repeating the computation until it fails or the predicate returns true
 /// </summary>
 /// <param name="ma">Computation to repeat</param>
 /// <param name="schedule">Scheduler strategy for repeating</param>
 /// <typeparam name="RT">Runtime</typeparam>
 /// <typeparam name="A">Computation bound value type</typeparam>
 /// <returns>The result of the last invocation of ma</returns>
 public static Aff <RT, A> RepeatUntil <RT, A>(this Aff <RT, A> ma, Schedule schedule, Func <A, bool> predicate) where RT : struct, HasCancel <RT> =>
 ScheduleAff <RT, A> .RepeatUntil(ma, schedule, predicate);
Exemple #4
0
 /// <summary>
 /// Keeps repeating the computation until it fails or the predicate returns true
 /// </summary>
 /// <param name="ma">Computation to repeat</param>
 /// <typeparam name="RT">Runtime</typeparam>
 /// <typeparam name="A">Computation bound value type</typeparam>
 /// <returns>The result of the last invocation of ma</returns>
 public static Aff <RT, A> repeatUntil <RT, A>(Aff <RT, A> ma, Func <A, bool> predicate) where RT : struct, HasCancel <RT> =>
 ScheduleAff <RT, A> .RepeatUntil(ma, Schedule.Forever, predicate);