private static bool ShouldIntercept <TRequest, TResponse>(CallInterceptorOptions interceptorOptions, Method <TRequest, TResponse> method) { if (!interceptorOptions.ServiceName.AreEqual(method.ServiceName)) { return(false); } if (!interceptorOptions.ResponseType.AreEqual(typeof(TResponse).Name)) { return(false); } return(true); }
public CallInterceptor(IOptions <CallInterceptorOptions> options, Channel channel) : base(channel) { _options = options.Value; }