public FeatureFlagState OrRule(FeatureFlagState p1, FeatureFlagState p2) { var or = new OrRule { Rules = new Rule[] { new ConstantRule { Value = p1 }, new ConstantRule { Value = p2 } } }; return(or.Evaluate(null)); }
public FeatureFlagState Override(bool?a1, FeatureFlagState a2) { var p = new DynamicFeatureFlagStateEvaluator(null, new FeatureRulesDefinition() { OverrideValue = a1, ContextualRules = new [] { new ConstantRule() { Value = a2 } } }); return(p.Evaluate(null)); }
public ConstantFeatureFlagStateEvaluator(string key, FeatureFlagState state) { Key = key; State = state; }
public StaticFeatureFlag(string name, FeatureFlagState state) { Name = name; State = state; }
public ConstantFeatureFlagStateEvaluator(FeatureFlagState state) { State = state; }