コード例 #1
0
        protected override IMessagePublishTopologyConfigurator CreateMessageTopology <T>(Type type)
        {
            var messageTopology = new AmazonSqsMessagePublishTopology <T>(_messageTopology.GetMessageTopology <T>());

            var connector = new ImplementedMessageTypeConnector <T>(this, messageTopology);

            ImplementedMessageTypeCache <T> .EnumerateImplementedTypes(connector);

            OnMessageTopologyCreated(messageTopology);

            return(messageTopology);
        }
コード例 #2
0
        protected virtual IMessagePublishTopologyConfigurator CreateMessageTopology <T>(Type type)
            where T : class
        {
            var messageTopology = new MessagePublishTopology <T>();

            var connector = new ImplementedMessageTypeConnector(this);

            ImplementedMessageTypeCache <T> .EnumerateImplementedTypes(connector);

            OnMessageTopologyCreated(messageTopology);

            return(messageTopology);
        }
コード例 #3
0
        protected override IMessagePublishTopologyConfigurator CreateMessageTopology <T>(Type type)
        {
            var exchangeTypeSelector = new MessageExchangeTypeSelector <T>(ExchangeTypeSelector);

            var messageTopology = new RabbitMqMessagePublishTopology <T>(_messageTopology.GetMessageTopology <T>(), exchangeTypeSelector);

            var connector = new ImplementedMessageTypeConnector <T>(this, messageTopology);

            ImplementedMessageTypeCache <T> .EnumerateImplementedTypes(connector);

            OnMessageTopologyCreated(messageTopology);

            return(messageTopology);
        }
コード例 #4
0
        IMessageSendPipeSpecification CreateMessageSpecification <T>(Type type)
            where T : class
        {
            var specification = new MessageSendPipeSpecification <T>();

            foreach (var pipeSpecification in _specifications)
            {
                specification.AddPipeSpecification(pipeSpecification);
            }

            _observers.MessageSpecificationCreated(specification);

            var connector = new ImplementedMessageTypeConnector <T>(this, specification);

            ImplementedMessageTypeCache <T> .EnumerateImplementedTypes(connector);

            return(specification);
        }
コード例 #5
0
        IMessagePublishPipeSpecification CreateMessageSpecification <T>(Type type)
            where T : class
        {
            var specification = new MessagePublishPipeSpecification <T>();

            lock (_lock)
            {
                foreach (IPipeSpecification <PublishContext> pipeSpecification in _specifications)
                {
                    specification.AddPipeSpecification(pipeSpecification);
                }
            }

            _observers.MessageSpecificationCreated(specification);

            var connector = new ImplementedMessageTypeConnector <T>(this, specification);

            ImplementedMessageTypeCache <T> .EnumerateImplementedTypes(connector);

            return(specification);
        }