Class ViewModelBase
Base class for ViewModels.
Inheritance
System.Object
ViewModelBase
Implements
System.ComponentModel.INotifyPropertyChanged
System.ComponentModel.IDataErrorInfo
System.ComponentModel.INotifyDataErrorInfo
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Sartorius.SAF.Presentation.Infrastructure
Assembly: Sartorius.SAF.Presentation.dll
Syntax
public abstract class ViewModelBase : ChangeTrackingObject, INotifyPropertyChanged, IDataErrorInfo, INotifyDataErrorInfo, INotifyDataPropertyChanged, IActiveAware, IClosingAware, IBusyAware
Properties
View SourceIsActive
Gets or sets a value indicating whether this instance is active. Interplay with Prism’s RegionActiveAwareBehavior
Declaration
public bool IsActive { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
|
IsBusy
Indicates whether the instance is busy.
Declaration
public bool IsBusy { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Methods
View SourceOnClosing()
Performs actions when the instance is closed.
Declaration
public virtual void OnClosing()
RaiseIsActiveChanged(EventArgs)
Invokes the is active changed event.
Declaration
protected virtual void RaiseIsActiveChanged(EventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.EventArgs | e | The System.EventArgs instance containing the event data. |
RaiseIsBusyChanged()
Raises the IsBusyChanged event
Declaration
protected virtual void RaiseIsBusyChanged()
SetCommandsStates(Boolean)
Sets the commands states.
Declaration
protected virtual void SetCommandsStates(bool value)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | value | if set to |
Events
View SourceIsActiveChanged
Occurs when active status changed.
Declaration
public event EventHandler IsActiveChanged
Event Type
Type | Description |
---|---|
System.EventHandler |
IsBusyChanged
Raised when IsBusy changed.
Declaration
public event EventHandler IsBusyChanged
Event Type
Type | Description |
---|---|
System.EventHandler |
Implements
System.ComponentModel.INotifyPropertyChanged
System.ComponentModel.IDataErrorInfo
System.ComponentModel.INotifyDataErrorInfo