Class DataTableCollectionViewWrapper
Represents the class that used to create the collection view for data table and data view.
Implements
Inherited Members
Namespace: Syncfusion.WinForms.DataGrid.Data
Assembly: Syncfusion.SfDataGrid.WinForms.dll
Syntax
public class DataTableCollectionViewWrapper : DataTableCollectionView, ICollectionViewAdv, IEnumerable, INotifyPropertyChanged, ISupportInitialize, IDisposable, IPropertyChangedEventHandler, IEditableCollectionView, IUnboundExpressionFunc, IGridViewNotifier
Constructors
DataTableCollectionViewWrapper(IEnumerable, SfDataGrid)
Initializes a new instance of the DataTableCollectionViewWrapper class. class.
Declaration
public DataTableCollectionViewWrapper(IEnumerable source, SfDataGrid dataGrid)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.IEnumerable | source | The source that need to be added as the DataTable or DataView. |
SfDataGrid | dataGrid | The grid that need to be assigned with the given source. |
Methods
AttachGridView(Object)
Initializes the grid.
Declaration
public override void AttachGridView(object dataGrid)
Parameters
Type | Name | Description |
---|---|---|
System.Object | dataGrid | The data Grid. |
Overrides
CanUpdateSummary(ISummaryRow, String)
The can update summary.
Declaration
protected override bool CanUpdateSummary(ISummaryRow row, string propertyName)
Parameters
Type | Name | Description |
---|---|---|
ISummaryRow | row | The row. |
System.String | propertyName | The property name. |
Returns
Type | Description |
---|---|
System.Boolean | The System.Boolean. |
Overrides
CreateItemPropertiesProvider()
Creates the property provider for the grid item.
Declaration
protected override ItemPropertiesProvider CreateItemPropertiesProvider()
Returns
Type | Description |
---|---|
ItemPropertiesProvider | Returns the ItemPropertiesProvider for the grid columns. |
Overrides
CreateRecords()
Creates the records to the grid based on the ItemsSource.
Declaration
protected override RecordsList CreateRecords()
Returns
Type | Description |
---|---|
RecordsList | Returns the RecordList collection. |
Overrides
CreateTopLevelGroup()
Creates a top-level group for the datagrid.
Declaration
protected override TopLevelGroup CreateTopLevelGroup()
Returns
Type | Description |
---|---|
TopLevelGroup | Returns the top-level group. |
Overrides
DetachGridView()
Clears the grid while Disposing the DataTableCollectionViewWrapper.
Declaration
public override void DetachGridView()
Overrides
Dispose(Boolean)
Disposes all the resources used by the DataTableCollectionViewWrapper class.
Declaration
protected override void Dispose(bool isDisposing)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | isDisposing | Indicates the call is from Dispose method. |
Overrides
GetDataGrid()
Gets the grid that attached to the collection view wrapper.
Declaration
public override object GetDataGrid()
Returns
Type | Description |
---|---|
System.Object | Returns the data grid. |
Overrides
GetFunc(String, DataOperation, DataReflectionMode)
Gets the func for corresponding data operation and property name.
Declaration
public override Func<string, object, object> GetFunc(string propertyName, DataOperation operation = DataOperation.Default, DataReflectionMode reflectionMode = DataReflectionMode.Value)
Parameters
Type | Name | Description |
---|---|---|
System.String | propertyName | The mapping name of the column. |
DataOperation | operation | The data operation that is being performed. |
DataReflectionMode | reflectionMode | The reflection mode for the operation. |
Returns
Type | Description |
---|---|
System.Func<System.String, System.Object, System.Object> | Returns the Func for the given data operation. |
Overrides
GetSelectedRecords()
Gets the selected records from SfDataGrid to calculate the selected records summaries.
Declaration
public override ObservableCollection<object> GetSelectedRecords()
Returns
Type | Description |
---|---|
System.Collections.ObjectModel.ObservableCollection<System.Object> | Returns the selected items collection |
Overrides
RefreshFilter(Boolean)
Clear Selection if the selected item is not in View
Declaration
public override void RefreshFilter(bool isProgrammatic)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | isProgrammatic | if View need to clear the selection in SFDataGrid, using View.RowFilter expression; set true. The default value is false. |