コード例 #1
0
 public static T Handle <T>(this IMessageDispatchInterceptor interceptor, T message) where T : IMessage
 => (T)interceptor.Handle(new List <IMessage> {
     message
 }).Invoke(0, message);
コード例 #2
0
 public IDisposable RegisterDispatchInterceptor(IMessageDispatchInterceptor dispatchInterceptor)
 {
     _dispatchInterceptors.TryAdd(dispatchInterceptor, null);
     return(Disposable.Create(() => _dispatchInterceptors.TryRemove(dispatchInterceptor, out _)));
 }
コード例 #3
0
 public override IDisposable RegisterHandlerInterceptor(IMessageDispatchInterceptor handlerInterceptor)
 {
     throw new NotImplementedException();
 }
コード例 #4
0
 public abstract IDisposable RegisterHandlerInterceptor(IMessageDispatchInterceptor handlerInterceptor);
コード例 #5
0
 public CommandGatewayFactory RegisterDispatchInterceptor(
     IMessageDispatchInterceptor dispatchInterceptor)
 {
     _dispatchInterceptors.Add(dispatchInterceptor);
     return(this);
 }