コード例 #1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="T:System.Object"/> class.
        /// </summary>
        public Dispatcher(DispatcherConfiguration configuration)
        {
            _serviceLocator = configuration.ServiceLocator ?? throw new ArgumentException("Unity Container is not registered for distributor.");
            _registry       = configuration.DispatcherHandlerRegistry ?? throw new ArgumentException("Dispatcher Handler Registry is null in distributor.");
            _maxRetries     = configuration.NumberOfRetries;

            // order handlers
            _registry.InsureOrderOfHandlers(configuration.Order);
        }
コード例 #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Object"/> class.
 /// </summary>
 public DispatcherConfiguration()
 {
     DispatcherHandlerRegistry = new DispatcherHandlerRegistry();
     NumberOfRetries           = 1;
     Order = new List <Type>();
 }