/// <summary> /// Initializes a new instance of the <see cref="AlternateTypeToCastleInterceptorAdapter" /> class. /// </summary> /// <param name="implementation">The implementation.</param> /// <param name="logger">The logger.</param> /// <param name="messageBroker">The message broker.</param> /// <param name="proxyFactory">The proxy factory.</param> /// <param name="timerStrategy">The timer strategy.</param> /// <param name="runtimePolicyStrategy">The runtime policy strategy.</param> /// <exception cref="System.ArgumentNullException">Throws an exception if either <paramref name="implementation"/> or <paramref name="logger"/> are <c>null</c>.</exception> public AlternateTypeToCastleInterceptorAdapter(IAlternateMethod implementation, ILogger logger, IMessageBroker messageBroker, IProxyFactory proxyFactory, Func<IExecutionTimer> timerStrategy, Func<RuntimePolicy> runtimePolicyStrategy) { if (implementation == null) { throw new ArgumentNullException("implementation"); } if (logger == null) { throw new ArgumentNullException("logger"); } Implementation = implementation; Logger = logger; MessageBroker = messageBroker; ProxyFactory = proxyFactory; TimerStrategy = timerStrategy; RuntimePolicyStrategy = runtimePolicyStrategy; }
/// <summary> /// Initializes a new instance of the <see cref="AlternateTypeToCastleInterceptorAdapter" /> class. /// </summary> /// <param name="implementation">The implementation.</param> /// <param name="logger">The logger.</param> /// <param name="messageBroker">The message broker.</param> /// <param name="proxyFactory">The proxy factory.</param> /// <param name="timerStrategy">The timer strategy.</param> /// <param name="runtimePolicyStrategy">The runtime policy strategy.</param> /// <exception cref="System.ArgumentNullException">Throws an exception if either <paramref name="implementation"/> or <paramref name="logger"/> are <c>null</c>.</exception> public AlternateTypeToCastleInterceptorAdapter(IAlternateMethod implementation, ILogger logger, IMessageBroker messageBroker, IProxyFactory proxyFactory, Func <IExecutionTimer> timerStrategy, Func <RuntimePolicy> runtimePolicyStrategy) { if (implementation == null) { throw new ArgumentNullException("implementation"); } if (logger == null) { throw new ArgumentNullException("logger"); } Implementation = implementation; Logger = logger; MessageBroker = messageBroker; ProxyFactory = proxyFactory; TimerStrategy = timerStrategy; RuntimePolicyStrategy = runtimePolicyStrategy; }