コード例 #1
0
        public Task <IListener> CreateListenerAsync(ListenerFactoryContext context)
        {
            if (context == null)
            {
                throw new ArgumentNullException("context");
            }

            WebHookListener listener = new WebHookListener(_dispatcher, _parameter, _route, context.Executor);

            return(Task.FromResult <IListener>(listener));
        }
        public Task<IListener> CreateListenerAsync(ListenerFactoryContext context)
        {
            if (context == null)
            {
                throw new ArgumentNullException("context");
            }

            WebHookListener listener = new WebHookListener(_dispatcher, (MethodInfo)_parameter.Member, _route, context.Executor);
            return Task.FromResult<IListener>(listener);
        }