Ejemplo n.º 1
0
        public Task SetFaulted(BehaviorContext <FutureState, TInput> context)
        {
            FutureConsumeContext <TInput> consumeContext = context.CreateFutureConsumeContext();

            return(consumeContext.Instance.HasSubscriptions()
                ? _endpoint.SendFault(consumeContext, consumeContext.Instance.Subscriptions.ToArray())
                : _endpoint.SendFault(consumeContext));
        }
Ejemplo n.º 2
0
        public Task Execute(BehaviorContext <FutureState, TInput> context)
        {
            FutureConsumeContext <TInput> consumeContext = context.CreateFutureConsumeContext();

            return(_executor.Execute(consumeContext));
        }
 public Task Execute(BehaviorContext <FutureState, T> context, Behavior <FutureState, T> next)
 {
     return(Execute(context.CreateFutureConsumeContext()));
 }
 public Task Execute(BehaviorContext <FutureState, Contracts.Request <T> > context, Behavior <FutureState, Contracts.Request <T> > next)
 {
     return(Execute(context.CreateFutureConsumeContext(context.Data.Request)));
 }
Ejemplo n.º 5
0
 public Task Send(BehaviorContext <FutureState, TCommand> context, TInput data)
 {
     return(data != null
         ? _requestEndpoint.SendCommand(context.CreateFutureConsumeContext(data))
         : TaskUtil.Completed);
 }