コード例 #1
0
 public ConsumerWorker(
     string connectionString,
     ConsumerProperties consumerProperties,
     IDependencyResolver dependencyResolver)
 {
     _connectionString   = connectionString;
     _consumerProperties = consumerProperties;
     _service            = dependencyResolver.Resolve <TService>();
     _serializer         = dependencyResolver.Resolve <ISerializer>();
 }
コード例 #2
0
 public ConsumerWorker <TService, TMessage> CreateConsumer <TService, TMessage>(ConsumerProperties consumerProperties)
     where TService : class, IMessageBusService <TMessage>
     where TMessage : class
 {
     return(new ConsumerWorker <TService, TMessage>(_connectionString, consumerProperties, _container));
 }