コード例 #1
0
 public LinkTopologyHandler(LinkTopologyConfigDelegate configAction, LinkTopologyReadyDelegate readyAction,
                            LinkTopologyErrorDelegate errorAction)
 {
     _configAction = configAction ?? throw new ArgumentNullException(nameof(configAction));
     _errorAction  = errorAction ?? throw new ArgumentNullException(nameof(errorAction));
     _readyAction  = readyAction ?? throw new ArgumentNullException(nameof(readyAction));
 }
コード例 #2
0
        public ILinkConsumerBuilder Queue(LinkConsumerTopologyConfigDelegate config, LinkTopologyErrorDelegate error)
        {
            if (config == null)
            {
                throw new ArgumentNullException(nameof(config));
            }

            if (error == null)
            {
                throw new ArgumentNullException(nameof(error));
            }

            return(Queue(new LinkConsumerTopologyHandler(config, error)));
        }
コード例 #3
0
        public ILinkTopologyBuilder Handler(
            LinkTopologyConfigDelegate config,
            LinkTopologyReadyDelegate ready,
            LinkTopologyErrorDelegate error
            )
        {
            if (config == null)
            {
                throw new ArgumentNullException(nameof(config));
            }

            if (ready == null)
            {
                throw new ArgumentNullException(nameof(ready));
            }

            if (error == null)
            {
                throw new ArgumentNullException(nameof(error));
            }

            return(Handler(new LinkTopologyHandler(config, ready, error)));
        }
コード例 #4
0
 public ILinkPullConsumerBuilder Queue(LinkConsumerTopologyConfigDelegate config,
                                       LinkTopologyErrorDelegate error)
 {
     return(new LinkPullConsumerBuilder(this, consumerBuilder: _consumerBuilder.Queue(config, error)));
 }