private DArray GetArray(IEnumerable <object> arrayObject, Type arrayType, int depth) { var array = new DArray(); object[] list = arrayObject.ToArray(); string type = arrayType.Name; array.TypeHeader = $"{type} ({list.Length} items)"; foreach (var item in list) { DObject arrayItem = GetDObject(item, depth); array.Add(arrayItem); if (arrayItem is DComplex complex) { array.AddColumns(complex.Properties.Select(p => p.Name)); } } return(array); }
public void AddProperty(string name, DObject value) { _properties.Add(new DProperty(name, value)); }
public void Add(DObject item) { _items.Add(item); }