Class PropertyChangedEventData
- Namespace
- Microsoft.EntityFrameworkCore.Diagnostics
- Assembly
- Microsoft.EntityFrameworkCore.dll
A DiagnosticSource event payload class for events that indicate a changed property value.
public class PropertyChangedEventData : PropertyEventData
- Inheritance
-
PropertyChangedEventData
- Inherited Members
Remarks
See Logging, events, and diagnostics for more information and examples.
Constructors
PropertyChangedEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData, string>, EntityEntry, IProperty, object?, object?)
Constructs the event payload.
public PropertyChangedEventData(EventDefinitionBase eventDefinition, Func<EventDefinitionBase, EventData, string> messageGenerator, EntityEntry entityEntry, IProperty property, object? oldValue, object? newValue)
Parameters
eventDefinition
EventDefinitionBaseThe event definition.
messageGenerator
Func<EventDefinitionBase, EventData, string>A delegate that generates a log message for this event.
entityEntry
EntityEntryThe entry for the entity instance on which the property value has changed.
property
IPropertyThe property.
oldValue
objectThe old value.
newValue
objectThe new value.
Properties
EntityEntry
The entry for the entity instance on which the property value has changed.
public virtual EntityEntry EntityEntry { get; }
Property Value
NewValue
The new value.
public virtual object? NewValue { get; }
Property Value
OldValue
The old value.
public virtual object? OldValue { get; }
Property Value
Property
The property.
public virtual IProperty Property { get; }