コード例 #1
0
            public async Task InterceptAsync(IPersistentRepresentation message)
            {
                var result = await _predicate(message);

                if ((_negate && !result) || (!_negate && result))
                {
                    await _next.InterceptAsync(message);
                }
            }
コード例 #2
0
            public async Task InterceptAsync(IPersistentRepresentation message)
            {
                var type = message.Payload.GetType();

                if (_messageType.IsAssignableFrom(type))
                {
                    await _next.InterceptAsync(message);
                }
            }
コード例 #3
0
            public async Task InterceptAsync(IPersistentRepresentation message)
            {
                await Task.Delay(_delay);

                await _next.InterceptAsync(message);
            }