public CodeFeatureStateCodeSwitch(ICodeFeatureStateCache cache) { _cache = cache; _evaluated = new CodeSwitchEvaluatedObservable <TFeature>(); _enabled = new Lazy <bool>(Evaluate); }
public ContextFeatureStateCodeSwitch(ICodeFeatureStateCache cache, IContextFeatureStateCache <TContext> contextCache, TContext context) { _cache = cache; _contextCache = contextCache; _context = context; _evaluated = new CodeSwitchEvaluatedObservable <TFeature>(); _enabled = new Lazy <bool>(Evaluate); }
public DateRangeCodeSwitch(bool switchEnabled, DateTime?enabledFrom, DateTime?enabledTo, CurrentTimeProvider currentTimeProvider) { _switchEnabled = switchEnabled; _enabledFrom = enabledFrom; _enabledTo = enabledTo; _currentTimeProvider = currentTimeProvider; _evaluated = new CodeSwitchEvaluatedObservable <TFeature>(); _enabled = new Lazy <bool>(Evaluate); }
public EnabledCodeSwitch() { _evaluated = new CodeSwitchEvaluatedObservable <TFeature>(); }
public EnabledForAuthenticatedIdentityCodeSwitch() { _evaluated = new CodeSwitchEvaluatedObservable <TFeature>(); _enabled = new Lazy <bool>(Evaluate); }
public EnabledForThreadPrincipalInRoleCodeSwitch(string role) { _role = role; _evaluated = new CodeSwitchEvaluatedObservable <TFeature>(); _enabled = new Lazy <bool>(Evaluate); }
public ToggleCodeSwitch(IToggleSwitchState <TFeature> toggleSwitchState) { _toggleSwitchState = toggleSwitchState; _evaluated = new CodeSwitchEvaluatedObservable <TFeature>(); _enabled = new Lazy <bool>(Evaluate); }