Show / Hide Table of Contents

Class ItemViewModelBase

Based on Microsoft.Internal.GamesTest.BugAnywhere.BugAnywhereObject This is the base implementation for all items in the Aruba View Model, it provides basic capabilities for Property changes and error notification.

Inheritance
object
BindableBase
ItemViewModelBase
FieldViewModel
TokenizedItemViewModel
Implements
INotifyPropertyChanged
IDataErrorInfo
Inherited Members
BindableBase.SetProperty<T>(ref T, T, string)
BindableBase.SetProperty<T>(ref T, T, Action, string)
BindableBase.RaisePropertyChanged(string)
BindableBase.OnPropertyChanged(PropertyChangedEventArgs)
BindableBase.PropertyChanged
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Phoenix.Aruba
Assembly: Phoenix.Plugin.Aruba.dll
Syntax
public abstract class ItemViewModelBase : BindableBase, INotifyPropertyChanged, IDataErrorInfo

Constructors

View Source

ItemViewModelBase(bool)

Initializes a new instance of the ItemViewModelBase class.

Declaration
protected ItemViewModelBase(bool canEdit)
Parameters
Type Name Description
bool canEdit

Whether this object can be edited.

Properties

View Source

CanEdit

Gets a value indicating whether this object can be edited.

Declaration
public virtual bool CanEdit { get; }
Property Value
Type Description
bool
View Source

Error

Gets or sets the error message for the object.

Declaration
public string Error { get; protected set; }
Property Value
Type Description
string
View Source

HasError

Gets or sets a value indicating whether this object has an error.

Declaration
public virtual bool HasError { get; protected set; }
Property Value
Type Description
bool
View Source

IsDirty

Gets or sets a value indicating whether this object has been edited without being saved.

Declaration
public bool IsDirty { get; protected set; }
Property Value
Type Description
bool

A value indicating whether this object has been edited without being saved.

View Source

this[string]

Retrieves an error message for the specified property.

Declaration
public string this[string columnName] { get; }
Parameters
Type Name Description
string columnName

The property to retrieve the error message for.

Property Value
Type Description
string

An error message.

Methods

View Source

MarkAllPropertiesAsValid()

Marks all properties as valid.

Declaration
protected void MarkAllPropertiesAsValid()
View Source

MarkPropertyAsInvalid(string, string)

Marks a property as invalid.

Declaration
protected void MarkPropertyAsInvalid(string propertyName, string message)
Parameters
Type Name Description
string propertyName

The name of the property.

string message

The error message.

View Source

MarkPropertyAsValid(string)

Marks a property as valid.

Declaration
protected void MarkPropertyAsValid(string propertyName)
Parameters
Type Name Description
string propertyName

The name of the property.

Implements

INotifyPropertyChanged
IDataErrorInfo
  • View Source
In this article
Back to top Generated by DocFX