public void DisplayNode(NodeEntity arg) { Blank(); foreach (AttributeEntity a in arg.GetAttrList()) { RowEntity add = new RowEntity(); add.TrySetMember(Column(0).GetBindName(), a.GetAttrName()); add.TrySetMember(Column(1).GetBindName(), a.GetAttrValue()); AddRow(add); } RowEntity nodeValue = new RowEntity(); nodeValue.TrySetMember(Column(0).GetBindName(), @"Node Value"); nodeValue.TrySetMember(Column(1).GetBindName(), arg.GetNodeValue()); AddRow(nodeValue); Refresh(); }
public void DisplayDirectory(FileSystemNode node) { Blank(); TryGetFiles(node.FullPath)?.ToList().ForEach(f => { var add = new RowEntity(); add.TrySetMember(Column(0).BindName, f); AddRow(add); }); }
private void FillTableList(List <List <object> > queryResult) { tableListOperator.Blank(); queryResult.ForEach(row => { var addRow = new RowEntity(); addRow.TrySetMember(@"TableName", row[0].ToString()); tableListOperator.AddRow(addRow); }); tableListOperator.Refresh(); }
public void DisplayDirectory(FileSystemNode arg) { Blank(); IEnumerable <string> files = TryGetFiles(arg.GetPath()); if (files == null) { return; } foreach (string item in files) { RowEntity add = new RowEntity(); add.TrySetMember(Column(0).GetBindName(), item); AddRow(add); } Refresh(); }
public void Show(SqliteAccessor accessor) { if (0 == accessor.QueryResultAttributes.Count || 0 == accessor.QueryResult.Count) { return; } accessor.QueryResultAttributes.ForEach(a => dataGridOperator.AddColumn(a.Item1, a.Item1)); dataGridOperator.CreateColumns(); accessor.QueryResult.ForEach(row => { var addRow = new RowEntity(); for (var i = 0; accessor.QueryResultAttributes.Count > i; ++i) { addRow.TrySetMember(accessor.QueryResultAttributes[i].Item1, accessor.IsBlobColumn(accessor.QueryResultAttributes, i) ? @"[Blob data]" : row[i]); } dataGridOperator.AddRow(addRow); }); dataGridOperator.Refresh(); }