/// <summary> /// Initializes a new instance of the <see cref="DefaultCommandHandlerSelector"/> class. /// </summary> /// <param name="configuration">The configuration.</param> public DefaultCommandHandlerSelector(ProcessorConfiguration configuration) { if (configuration == null) { throw Error.ArgumentNull("configuration"); } this.handlerInfoCache = new Lazy <ConcurrentDictionary <Type, CommandHandlerDescriptor> >(this.InitializeHandlerInfoCache); this.configuration = configuration; this.commandHandlerTypeCache = new CommandHandlerTypeCache(this.configuration); }
/// <summary> /// Initializes a new instance of the <see cref="DefaultCommandHandlerSelector"/> class. /// </summary> /// <param name="configuration">The configuration.</param> public DefaultCommandHandlerSelector(ProcessorConfiguration configuration) { if (configuration == null) { throw Error.ArgumentNull("configuration"); } this.handlerInfoCache = new Lazy<ConcurrentDictionary<Type, CommandHandlerDescriptor>>(this.InitializeHandlerInfoCache); this.configuration = configuration; this.commandHandlerTypeCache = new CommandHandlerTypeCache(this.configuration); }