/// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public InterceptorInvocationContext(IMessageHandlerInterceptor interceptor, InvocationContext context)
 {
     _interceptor = interceptor;
     _context     = context;
 }
Пример #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public DispatcherInterceptorContext(IMessageHandlerInterceptor interceptor, DispatcherInvocationContext context)
 {
     _interceptor = interceptor;
     _context     = context;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public DispatcherInterceptorContext(IMessageHandlerInterceptor interceptor, DispatcherInvocationContext context)
 {
     _interceptor = interceptor;
     _context = context;
 }
 public IDisposable RegisterHandlerInterceptor(IMessageHandlerInterceptor handlerInterceptor)
 {
     _handlerInterceptors.TryAdd(handlerInterceptor, null);
     return(Disposable.Create(() => _handlerInterceptors.TryRemove(handlerInterceptor, out _)));
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public InterceptorInvocationContext(IMessageHandlerInterceptor interceptor, InvocationContext context)
 {
     _interceptor = interceptor;
     _context = context;
 }