DbSet.Local Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets an ObservableCollection<T> that represents a local view of all Added, Unchanged, and Modified entities in this set. This local view will stay in sync as entities are added or removed from the context. Likewise, entities added to or removed from the local view will automatically be added to or removed from the context.
public virtual System.Collections.IList Local { get; }
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1065:DoNotRaiseExceptionsInUnexpectedLocations")]
public virtual System.Collections.IList Local { get; }
member this.Local : System.Collections.IList
Public Overridable ReadOnly Property Local As IList
Property Value
The local view.
- Attributes
Remarks
This property can be used for data binding by populating the set with data, for example by using the Load extension method, and then binding to the local data through this property. For WPF bind to this property directly. For Windows Forms bind to the result of calling ToBindingList on this property
Applies to
Entity Framework