public System.Collections.Hashtable GetHash(String expression) { var result = this.Eval(expression); using (var inspector = new Inspecting.ObjectInspector(result)) { var hash = inspector.GetHash(); return(hash); } }
public Hashtable GetHash() { Hashtable result = new Hashtable(); List <String> names = GetNames(); foreach (var name in names) { var value = GetValue <object>(name); if (value.GetType().GUID.Equals(Guid.Empty)) { using (var inspector = new ObjectInspector(value)) { var valueNames = inspector.GetNames(); object newValue = null; if (valueNames.Count > 0) { if (valueNames[0] == "0") { newValue = inspector.GetList(); } else { newValue = inspector.GetHash(); } result.Add(name, newValue); } } } else { result.Add(name, value); } } return(result); }