diff --git a/src/OpenFeature.SDK/Model/EvaluationContext.cs b/src/OpenFeature.SDK/Model/EvaluationContext.cs index b8ce9afa..cd73b2cc 100644 --- a/src/OpenFeature.SDK/Model/EvaluationContext.cs +++ b/src/OpenFeature.SDK/Model/EvaluationContext.cs @@ -15,35 +15,50 @@ public class EvaluationContext /// /// Gets the Value at the specified key /// - /// - /// + /// The key of the value to be retrieved + /// The associated with the key + /// + /// Thrown when the context does not contain the specified key + /// + /// + /// Thrown when the key is + /// public Value GetValue(string key) => this._structure.GetValue(key); /// /// Bool indicating if the specified key exists in the evaluation context /// - /// - /// + /// The key of the value to be checked + /// indicating the presence of the key + /// + /// Thrown when the key is + /// public bool ContainsKey(string key) => this._structure.ContainsKey(key); /// /// Removes the Value at the specified key /// - /// + /// The key of the value to be removed + /// + /// Thrown when the key is + /// public void Remove(string key) => this._structure.Remove(key); /// /// Gets the value associated with the specified key /// - /// - /// - /// + /// The or if the key was not present + /// The key of the value to be retrieved + /// indicating the presence of the key + /// + /// Thrown when the key is + /// public bool TryGetValue(string key, out Value value) => this._structure.TryGetValue(key, out value); /// /// Gets all values as a Dictionary /// - /// + /// New representation of this Structure public IDictionary AsDictionary() { return new Dictionary(this._structure.AsDictionary()); @@ -52,9 +67,15 @@ public IDictionary AsDictionary() /// /// Add a new bool Value to the evaluation context /// - /// - /// - /// + /// The key of the value to be added + /// The value to be added + /// This + /// + /// Thrown when the key is + /// + /// + /// Thrown when an element with the same key is already contained in the context + /// public EvaluationContext Add(string key, bool value) { this._structure.Add(key, value); @@ -64,9 +85,15 @@ public EvaluationContext Add(string key, bool value) /// /// Add a new string Value to the evaluation context /// - /// - /// - /// + /// The key of the value to be added + /// The value to be added + /// This + /// + /// Thrown when the key is + /// + /// + /// Thrown when an element with the same key is already contained in the context + /// public EvaluationContext Add(string key, string value) { this._structure.Add(key, value); @@ -76,9 +103,15 @@ public EvaluationContext Add(string key, string value) /// /// Add a new int Value to the evaluation context /// - /// - /// - /// + /// The key of the value to be added + /// The value to be added + /// This + /// + /// Thrown when the key is + /// + /// + /// Thrown when an element with the same key is already contained in the context + /// public EvaluationContext Add(string key, int value) { this._structure.Add(key, value); @@ -88,9 +121,15 @@ public EvaluationContext Add(string key, int value) /// /// Add a new double Value to the evaluation context /// - /// - /// - /// + /// The key of the value to be added + /// The value to be added + /// This + /// + /// Thrown when the key is + /// + /// + /// Thrown when an element with the same key is already contained in the context + /// public EvaluationContext Add(string key, double value) { this._structure.Add(key, value); @@ -100,9 +139,15 @@ public EvaluationContext Add(string key, double value) /// /// Add a new DateTime Value to the evaluation context /// - /// - /// - /// + /// The key of the value to be added + /// The value to be added + /// This + /// + /// Thrown when the key is + /// + /// + /// Thrown when an element with the same key is already contained in the context + /// public EvaluationContext Add(string key, DateTime value) { this._structure.Add(key, value); @@ -112,9 +157,15 @@ public EvaluationContext Add(string key, DateTime value) /// /// Add a new Structure Value to the evaluation context /// - /// - /// - /// + /// The key of the value to be added + /// The value to be added + /// This + /// + /// Thrown when the key is + /// + /// + /// Thrown when an element with the same key is already contained in the context + /// public EvaluationContext Add(string key, Structure value) { this._structure.Add(key, value); @@ -124,9 +175,15 @@ public EvaluationContext Add(string key, Structure value) /// /// Add a new List Value to the evaluation context /// - /// - /// - /// + /// The key of the value to be added + /// The value to be added + /// This + /// + /// Thrown when the key is + /// + /// + /// Thrown when an element with the same key is already contained in the context + /// public EvaluationContext Add(string key, List value) { this._structure.Add(key, value); @@ -136,9 +193,15 @@ public EvaluationContext Add(string key, List value) /// /// Add a new Value to the evaluation context /// - /// - /// - /// + /// The key of the value to be added + /// The value to be added + /// This + /// + /// Thrown when the key is + /// + /// + /// Thrown when an element with the same key is already contained in the context + /// public EvaluationContext Add(string key, Value value) { this._structure.Add(key, value); @@ -173,7 +236,7 @@ public void Merge(EvaluationContext other) /// /// Return an enumerator for all values /// - /// + /// An enumerator for all values public IEnumerator> GetEnumerator() { return this._structure.GetEnumerator();