Exemplo n.º 1
0
 public static IScheduledActionsBuilder Schedule(
     [NotNull] this IScheduledActionsBuilder builder,
     [NotNull] string name,
     [NotNull] IScheduler scheduler,
     [NotNull] Func <Task> payload,
     [NotNull] ScheduledActionOptions options)
 => builder.Schedule(name, scheduler, _ => payload(), options);
 public static IScheduledActionsBuilder Schedule <TArg>(
     [NotNull] this IScheduledActionsBuilder builder,
     [NotNull] string name,
     [NotNull] IScheduler scheduler,
     [NotNull] Func <TArg, IScheduledActionContext, Task> payload,
     [NotNull] ScheduledActionOptions options)
 => builder.Schedule(name, scheduler, context => payload(ExtractArgumentFromOnDemandScheduler <TArg>(scheduler), context), options);
 public static IScheduledActionsBuilder Schedule <TArg>(
     [NotNull] this IScheduledActionsBuilder builder,
     [NotNull] string name,
     [NotNull] IScheduler scheduler,
     [NotNull] Action <TArg> payload,
     [NotNull] ScheduledActionOptions options)
 => builder.Schedule(name, scheduler, _ => payload(ExtractArgumentFromOnDemandScheduler <TArg>(scheduler)), options);
Exemplo n.º 4
0
 public static IScheduledActionsBuilder Schedule(
     [NotNull] this IScheduledActionsBuilder builder,
     [NotNull] string name,
     [NotNull] IScheduler scheduler,
     [NotNull] Action payload)
 => builder.Schedule(name, scheduler, _ => payload());
 protected abstract Task SetupAsync([NotNull] IScheduledActionsBuilder builder, [NotNull] IVostokHostingEnvironment environment);
 public override void Setup(IScheduledActionsBuilder builder, IVostokHostingEnvironment environment)
 => setup(builder, environment);
 public abstract void Setup([NotNull] IScheduledActionsBuilder builder, [NotNull] IVostokHostingEnvironment environment);
 public static IScheduledActionsBuilder Schedule <TArg>(
     [NotNull] this IScheduledActionsBuilder builder,
     [NotNull] string name,
     [NotNull] IScheduler scheduler,
     [NotNull] Action <TArg, IScheduledActionContext> payload)
 => builder.Schedule(name, scheduler, context => payload(ExtractArgumentFromOnDemandScheduler <TArg>(scheduler), context));
 public static IScheduledActionsBuilder Schedule <TArg>(
     [NotNull] this IScheduledActionsBuilder builder,
     [NotNull] string name,
     [NotNull] IScheduler scheduler,
     [NotNull] Func <TArg, Task> payload)
 => builder.Schedule(name, scheduler, _ => payload(ExtractArgumentFromOnDemandScheduler <TArg>(scheduler)));