NotifyCanExecuteChangedForAttribute

Ecng.ComponentModel

Placed alongside ObservablePropertyAttribute on a backing field: when the generated property changes, the generator calls RaiseCanExecuteChanged on the listed commands. Mirrors CommunityToolkit.Mvvm.ComponentModel.NotifyCanExecuteChangedForAttribute.

Наследует: Attribute

Конструкторы

NotifyCanExecuteChangedForAttribute
public NotifyCanExecuteChangedForAttribute(string commandName)
notifyCanExecuteChangedForAttribute = NotifyCanExecuteChangedForAttribute(commandName)

Initializes a new instance of the NotifyCanExecuteChangedForAttribute class.

commandName
The command whose CanExecuteChanged must be raised.
NotifyCanExecuteChangedForAttribute
public NotifyCanExecuteChangedForAttribute(string commandName, string[] otherCommandNames)
notifyCanExecuteChangedForAttribute = NotifyCanExecuteChangedForAttribute(commandName, otherCommandNames)

Initializes a new instance of the NotifyCanExecuteChangedForAttribute class.

commandName
The command whose CanExecuteChanged must be raised.
otherCommandNames
Additional command names.

Свойства

CommandName
public string CommandName { get; }
value = notifyCanExecuteChangedForAttribute.CommandName

The primary command name.

OtherCommandNames
public string[] OtherCommandNames { get; }
value = notifyCanExecuteChangedForAttribute.OtherCommandNames

Additional command names.