Show / Hide Table of Contents

Class EntityViewModel<T>

Clase base para un ViewModelBase cuyos campos de almacenamiento sean parte de un modelo de entidad.

Inheritance
object
NotifyPropertyChangeBase
NotifyPropertyChanged
ViewModelBase
EntityViewModel<T>
Implements
INotifyPropertyChangeBase
IRefreshable
IEntityViewModel<T>
IEntityViewModel
INotifyPropertyChanged
Inherited Members
ViewModelBase.IsBusy
ViewModelBase.Observe<T>(Expression<Func<T>>, Action)
ViewModelBase.Observe(Expression<Func<object>>[], Action)
ViewModelBase.Observe(string, Action)
ViewModelBase.Observe(string[], Action)
ViewModelBase.ObserveFrom<T>(T, Expression<Func<T, object>>, Action)
ViewModelBase.ObserveFrom(INotifyPropertyChanged, PropertyInfo, Action)
ViewModelBase.BusyOp(Action)
ViewModelBase.BusyOp(Task)
ViewModelBase.BusyOp<T>(Func<T>)
ViewModelBase.BusyOp<T>(Task<T>)
NotifyPropertyChanged.PropertyChanged
NotifyPropertyChanged.Notify(params string[])
NotifyPropertyChanged.Notify(string)
NotifyPropertyChanged.RaisePropertyChangeEvent(in string, in PropertyChangeNotificationType)
NotifyPropertyChanged.OnDoChange<T>(ref T, T, string)
NotifyPropertyChangeBase.OnInitialize(NotifyPropertyChangeBase.IPropertyBroadcastSetup)
NotifyPropertyChangeBase.Subscribe(PropertyInfo, PropertyChangeObserver)
NotifyPropertyChangeBase.Subscribe(PropertyChangeObserver)
NotifyPropertyChangeBase.Subscribe(Expression<Func<object>>, PropertyChangeObserver)
NotifyPropertyChangeBase.Unsubscribe(PropertyChangeObserver)
NotifyPropertyChangeBase.Unsubscribe(PropertyInfo)
NotifyPropertyChangeBase.Unsubscribe(Expression<Func<object>>)
NotifyPropertyChangeBase.Change<T>(ref T, T, string)
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: TheXDS.MCART.Types.Base
Assembly: MCART.Mvvm.dll
Syntax
public class EntityViewModel<T> : ViewModelBase, INotifyPropertyChangeBase, IRefreshable, IEntityViewModel<T>, IEntityViewModel, INotifyPropertyChanged
Type Parameters
Name Description
T

Tipo de entidad a utilizar como almacenamiento interno de este ViewModel.

Properties

| Edit this page View Source

Entity

Instancia de la entidad controlada por este ViewModel.

Declaration
public virtual T Entity { get; set; }
Property Value
Type Description
T

Methods

| Edit this page View Source

Refresh()

Notifica al sistema que las propiedades de este EntityViewModel<T> han cambiado.

Declaration
public override void Refresh()
Overrides
NotifyPropertyChangeBase.Refresh()
| Edit this page View Source

Update(T)

Edita la instancia de T dentro de este ViewModel.

Declaration
public virtual void Update(T entity)
Parameters
Type Name Description
T entity

Entidad con los nuevos valores a establecer en la entidad actualmente establecida en la propiedad Entity.

Operators

| Edit this page View Source

implicit operator T(EntityViewModel<T>)

Convierte implícitamente un EntityViewModel<T> en un T.

Declaration
public static implicit operator T(EntityViewModel<T> vm)
Parameters
Type Name Description
EntityViewModel<T> vm

EntityViewModel<T> a convertir.

Returns
Type Description
T

Implements

INotifyPropertyChangeBase
IRefreshable
IEntityViewModel<T>
IEntityViewModel
INotifyPropertyChanged

Extension Methods

Objects.ShallowCopyTo(object, object, Type)
ObjectExtensions.FieldsOf<T>(object)
ObjectExtensions.GetAttribute<T>(object)
ObjectExtensions.GetAttributes<T>(object)
ObjectExtensions.HasAttrValue<TAttribute, TValue>(object, out TValue)
ObjectExtensions.HasAttribute<T>(object)
ObjectExtensions.HasAttribute<T>(object, out T?)
ObjectExtensions.HasAttributes<T>(object, out IEnumerable<T>?)
ObjectExtensions.Is(object?, object?)
ObjectExtensions.IsEither(object, IEnumerable)
ObjectExtensions.IsEither(object, params object[])
ObjectExtensions.IsNeither(object, IEnumerable)
ObjectExtensions.IsNeither(object, params object[])
ObjectExtensions.IsNot(object?, object?)
ObjectExtensions.PropertiesOf<T>(object)
ObjectExtensions.WhichAre(object, IEnumerable<object>)
ObjectExtensions.WhichAre(object, params object[])
Common.IfNotNull<T>(T?, Action<T>)
Objects.Itself<T>(T)
Objects.ShallowClone<T>(T)
Objects.ShallowCopyTo<T>(T, T)
ObservingCommandBuilder.Create<T>(T, Action)
ObservingCommandBuilder.Create<T>(T, Action<object?>)
ObservingCommandBuilder.Create<T>(T, Func<object?, Task>)
ObservingCommandBuilder.Create<T>(T, Func<Task>)
CollectionExtensions.PushInto<TItem, TCollection>(TItem, ICollection<TCollection>)
DictionaryExtensions.PushInto<TKey, TValue>(TValue, TKey, IDictionary<TKey, TValue>)
NotifyPropertyChangeBaseExtensions.Subscribe<T>(T, Expression<Func<T, object?>>, PropertyChangeObserver)
NotifyPropertyChangeBaseExtensions.Unsubscribe<T>(T, Expression<Func<T, object?>>)
  • Edit this page
  • View Source
In this article
Back to top Generated by DocFX