Provides an object for loading, paging, filtering, sorting, and editing entities coming from EntityFrameworkCore's DbContext.
Definition
Namespace:Telerik.Windows.Controls
Assembly:Telerik.Windows.Controls.EntityFrameworkCore.dll
Syntax:
[TelerikToolboxCategory("Data")]
public class RadEntityFrameworkCoreDataSource : Control
Inheritance: objectRadEntityFrameworkCoreDataSource
Constructors
Initializes a new instance of the RadEntityFrameworkCoreDataSource class.
public RadEntityFrameworkCoreDataSource()
Fields
DbContextProperty
DependencyProperty
Identifies DbContext dependency property.
public static readonly DependencyProperty DbContextProperty
QueryNameProperty
DependencyProperty
Identifies QueryName dependency property.
public static readonly DependencyProperty QueryNameProperty
Properties
Gets the current view of entities resulting from the last load operation, using a DataItemCollection.
public DataItemCollection DataView { get; }
The current view of entities resulting from the last load operation.
DbContext
DbContext
Gets or sets the DbContext instance used for executing the load and submit operations.
public DbContext DbContext { get; set; }
The context.
Gets the filter descriptors used for filtering operations.
public CompositeFilterDescriptorCollection FilterDescriptors { get; }
The filter descriptors.
Gets the group descriptors used for grouping operations.
public GroupDescriptorCollection GroupDescriptors { get; }
The group descriptors.
Gets the command for loading data.
public ICommand LoadCommand { get; }
The command for loading data.
Gets or sets the name of the query to use for loading.
public string QueryName { get; set; }
The name of the query to use for loading data.
The names of the related entities.
public Collection<string> RelatedObjects { get; }
The names of the related entities.
For example, if your main entity set is called "Orders", you might want to add "OrderDetails" to this collection in case you want to get the related OrderDetails for each Order from the database.
Gets the sort descriptors used for sorting operations.
public SortDescriptorCollection SortDescriptors { get; }
The sort descriptors.
Gets the command for submitting changes.
public ICommand SubmitChangesCommand { get; }
The command for submitting changes.
Methods
Creates the view.
protected virtual QueryableCollectionView CreateView()
The view.
Initiates a Load operation if possible.
public void Load()
Initiates a Submit operation if possible.
public void SubmitChanges()