Last active
March 25, 2016 17:20
-
-
Save gindyo/c46ffb7b0ad5c6ae6f16 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
namespace Glimpse.Core.Extensibility | |
{ | |
/// <summary> | |
/// The context passed into the <c>Setup</c> method of <see cref="IInspector"/>. | |
/// </summary> | |
public class InspectorContext : IInspectorContext | |
{ | |
public InspectorContext(ILogger logger, IProxyFactory proxyFactory, IMessageBroker messageBroker, Func<IExecutionTimer> timerStrategy, Func<RuntimePolicy> runtimePolicyStrategy) | |
{ | |
if (logger == null) | |
{ | |
throw new ArgumentNullException("logger"); | |
} | |
if (proxyFactory == null) | |
{ | |
throw new ArgumentNullException("proxyFactory"); | |
} | |
if (messageBroker == null) | |
{ | |
throw new ArgumentNullException("messageBroker"); | |
} | |
if (timerStrategy == null) | |
{ | |
throw new ArgumentNullException("timerStrategy"); | |
} | |
if (runtimePolicyStrategy == null) | |
{ | |
throw new ArgumentNullException("runtimePolicyStrategy"); | |
} | |
Logger = logger; | |
ProxyFactory = proxyFactory; | |
TimerStrategy = timerStrategy; | |
MessageBroker = messageBroker; | |
RuntimePolicyStrategy = runtimePolicyStrategy; | |
} | |
public ILogger Logger { get; set; } | |
public IProxyFactory ProxyFactory { get; set; } | |
public Func<IExecutionTimer> TimerStrategy { get; set; } | |
public IMessageBroker MessageBroker { get; set; } | |
public Func<RuntimePolicy> RuntimePolicyStrategy { get; set; } | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment