EntityTracker

Namespace: Babel.Data Assembly: Babel.Data.dll

Provides a base class for entities that require change tracking.

public class EntityTracker : INotifyPropertyChanged

Inheritance

objectEntityTracker

Derived

ApiKey, Assembly, Contact, Customer, CustomerResource, Download, DownloadHistory, License, LicenseTemplate, LicenseToken, LogEntry, Order, OrderResource, Product, ProductAssembly, ProductLicense, ProductOrder, ProductResource, Release, ReleaseResource, Report, ReportProperty, Resource, Script, ScriptTag, Setting

Implements

INotifyPropertyChanged

Inherited Members

object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Constructors

EntityTracker()

public EntityTracker()

Properties

IsDirty

Gets or sets a value indicating whether the entity has been modified.

public bool IsDirty { get; set; }

Property Value

bool

Methods

SetWithNotify<T>(T, ref T, string)

Sets the value of a property and raises the PropertyChanged event if the value has changed.

protected void SetWithNotify<T>(T value, ref T field, string propertyName = "")

Parameters

NameDescription

value T

The new value of the property.

field T

A reference to the backing field of the property.

propertyName string

The name of the property. This parameter is optional and is automatically set by the compiler.

Type Parameters

NameDescription

T

The type of the property.

PropertyChanged

Occurs when a property value changes.

public event PropertyChangedEventHandler PropertyChanged

Event Type

PropertyChangedEventHandler

Last updated