Changeset 10512
- Timestamp:
- 02/25/14 16:16:07 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Scripting/3.3/UserScriptBase.cs
r10511 r10512 21 21 22 22 using System; 23 using System.Collections; 24 using System.Collections.Generic; 23 25 using System.Dynamic; 24 26 using System.IO; … … 52 54 } 53 55 54 protected class Variables : DynamicObject {56 protected class Variables : DynamicObject, IEnumerable<KeyValuePair<string, object>> { 55 57 private readonly VariableStore variableStore; 58 59 public ICollection<string> Keys { 60 get { return variableStore.Keys; } 61 } 62 63 public ICollection<object> Values { 64 get { return variableStore.Values; } 65 } 56 66 57 67 public Variables(VariableStore variableStore) { … … 70 80 public bool Contains(string variableName) { 71 81 return variableStore.ContainsKey(variableName); 82 } 83 84 public IEnumerator<KeyValuePair<string, object>> GetEnumerator() { 85 return variableStore.GetEnumerator(); 86 } 87 88 IEnumerator IEnumerable.GetEnumerator() { 89 return GetEnumerator(); 72 90 } 73 91 }
Note: See TracChangeset
for help on using the changeset viewer.