protected int CountOf(DataGridColumn <TItem> column)
 {
     return(Data.Count(x => column.GetValue(x) != null));
 }
Пример #2
0
 protected object Calculate(DataGridAggregate <TItem> aggregate, DataGridColumn <TItem> column)
 => aggregate?.AggregationFunction?.Invoke(Data, column);
Пример #3
0
 protected bool CellAreEditable(DataGridColumn <TItem> column)
 {
     return(column.Editable &&
            ((column.CellsEditableOnNewCommand && ParentDataGrid?.EditState == DataGridEditState.New) ||
             (column.CellsEditableOnEditCommand && ParentDataGrid?.EditState == DataGridEditState.Edit)));
 }
Пример #4
0
 /// <summary>
 /// Count all values that are not null.
 /// </summary>
 public static object Count(IEnumerable <TItem> Data, DataGridColumn <TItem> column)
 {
     return(Data.Count(x => column.GetValue(x) != null));
 }